Announcement

Collapse
No announcement yet.

horizontal line sounds

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • horizontal line sounds

    Is there an *.efs formula that will sound an alert of my choice when
    1) Prices cross above and close above , or
    2) Prices cross below and close below,
    a horizontal line?

  • #2
    try this for starters

    /************************************************** ******************
    Copyright © eSignal, 2003
    Title: Horizontal Line at X
    Version: 1.0

    ================================================== ===================
    Fix History:


    ================================================== ===================
    Project Description:

    This formula will place a horizontal line at a given price level.
    Please note that the price level must be defined in the Edit Studies window
    before any lines are drawn. If multiple lines are needed, please create
    another instance of the formula.

    ************************************************** ********************/


    function preMain() {
    setPriceStudy(true);
    setStudyTitle("Horizontal Line at X");
    setShowCursorLabel(false);

    var fp1 = new FunctionParameter("PriceLevel", FunctionParameter.NUMBER);

    var fp2 = new FunctionParameter("Color", FunctionParameter.COLOR);
    fp2.setDefault(Color.black);

    var fp3 = new FunctionParameter("Thickness", FunctionParameter.NUMBER);
    fp3.setDefault(1);


    }

    function main(PriceLevel,Color,Thickness) {

    if (PriceLevel == null) return;

    addBand(PriceLevel,PS_SOLID,Thickness,Color," ");

    if(close(-1)>Pricelevel)Alert.playSound("C:\\Program Files\\eSignal\\Sounds\\Ding.wav")

    return;
    }

    Comment

    Working...
    X