Download MetaTrader 5
To add comments, please log in or register
Join MQL5 Cloud Network. Start earning money!
niquedegraaff
63
niquedegraaff 2016.07.08 01:02 

Hello,

I'm currently writing a simple Expert Adviser that uses a arrow indicator.  
The problem I have is that the indicator does not paint it's objects until the expert has finished... visually seen, this is of course horrific design. 
Is this normal behavior? I should see it live right? Why isn't it live?


See in this video:
https://youtu.be/NbQp4XpR1Js

 

 

void OnTick()
{
    if(TotalOrdersCount() == 0)
    { 
        double atr        = iATR(Symbol(), PERIOD_M5, 14, 1);
        double sign_sell  = iCustom(Symbol(), PERIOD_M5, "Super_Indicator_V2 nrp", 7, 0, 1);
        double sign_buy   = iCustom(Symbol(), PERIOD_M5, "Super_Indicator_V2 nrp", 7, 1, 1);
    }
}
Fernando Carreiro
1451
Fernando Carreiro 2016.07.08 01:34  

It is normal behavior. You will not see and Indicators used or called from an EA, even if they are Custom Indicators.

In order to have a visual reference, you have to attach the same indicators manually to the chart and set the same parameter values as those being used in the EA.

To save time, set it up on a clean chart and then save it as a template, which you can then apply when you have need for it. You can also save it as a template with the name "Tester" if you want it to be automatically applied, every time you start the Visual Mode testing.

PS! You can directly add videos to your post here on the forum by using the "video" icon in the toolbar. There is no need to place it externally on YouTube. In fact, it is preferable that you edit you post and do so, so that the video will always be available in the future, irrespective of external sources.

niquedegraaff
63
niquedegraaff 2016.07.08 02:37  
FMIC:

It is normal behavior. You will not see and Indicators used or called from an EA, even if they are Custom Indicators.

In order to have a visual reference, you have to attach the same indicators manually to the chart and set the same parameter values as those being used in the EA.

To save time, set it up on a clean chart and then save it as a template, which you can then apply when you have need for it. You can also save it as a template with the name "Tester" if you want it to be automatically applied, every time you start the Visual Mode testing.

PS! You can directly add videos to your post here on the forum by using the "video" icon in the toolbar. There is no need to place it externally on YouTube. In fact, it is preferable that you edit you post and do so, so that the video will always be available in the future, irrespective of external sources.

The insert button of the youtube feature on the site doesn't work. It just hangs. 

Thanks for the explanation. 
Keith Watford
Moderator
7906
Keith Watford 2016.07.08 04:30  
FMIC:

To save time, set it up on a clean chart and then save it as a template, which you can then apply when you have need for it. You can also save it as a template with the name "Tester" if you want it to be automatically applied, every time you start the Visual Mode testing.


Also, if you save the template with the same name as the EA, it will automatically be used when testing that EA
Fernando Carreiro
1451
Fernando Carreiro 2016.07.08 11:42  
GumRai:
Also, if you save the template with the same name as the EA, it will automatically be used when testing that EA
Thanks for the reminder! I had forgotten about that one!
/
To add comments, please log in or register