Announcement

Collapse
No announcement yet.

Formulas not loading at startup

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

  • Formulas not loading at startup

    Are there any bugs with loading formulas? I have a problem where when I start ESignal sometimes my formula does not load and even clicking reload on the formula does nothing. I have to remove the formula and then select the formula again for it to work correctly. Other times the formula will be loaded and look fine and then I change the interval from a day to 5 minute on the chart window and then I go back to a day and the formula isn't working anymore. I try the same thing "reload" and it doesn't work then I have to remove the formula and select it again and then the formula works correctly.

    Here's the formula, it just displays up bars green and down bars red

    function preMain() {
    setPriceStudy(true);
    setShowCursorLabel(false);
    setDefaultPriceBarColor( Color.grey);

    }

    function main() {

    if ( close(-1) > close()){
    setPriceBarColor(Color.red);
    }
    else{
    setPriceBarColor(Color.RGB(0,178,0));
    }

    return;
    }


    Thanks,
    -Todd

  • #2
    Re: Formulas not loading at startup

    Todd
    As indicated in this article of the EFS KnowledgeBase the setPriceBarColor() function needs to be used in conjunction with the setColorPriceBars() and setDefaultPriceBarColor() statements in preMain
    Once you make the necessary addition the formula should work fine
    Alex


    Originally posted by reedtc
    Are there any bugs with loading formulas? I have a problem where when I start ESignal sometimes my formula does not load and even clicking reload on the formula does nothing. I have to remove the formula and then select the formula again for it to work correctly. Other times the formula will be loaded and look fine and then I change the interval from a day to 5 minute on the chart window and then I go back to a day and the formula isn't working anymore. I try the same thing "reload" and it doesn't work then I have to remove the formula and select it again and then the formula works correctly.

    Here's the formula, it just displays up bars green and down bars red

    function preMain() {
    setPriceStudy(true);
    setShowCursorLabel(false);
    setDefaultPriceBarColor( Color.grey);

    }

    function main() {

    if ( close(-1) > close()){
    setPriceBarColor(Color.red);
    }
    else{
    setPriceBarColor(Color.RGB(0,178,0));
    }

    return;
    }


    Thanks,
    -Todd

    Comment

    Working...
    X