Is it possible to call same indicator via the iCustom() function more than once within one tick?
I am thinking to use constant MODE value and variable PARAMETERS to multiplex data to same buffer[shift], thus creating serial like output from an indicator.
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
Is it possible to call same indicator via the iCustom() function more than once within one tick?
I am thinking to use constant MODE value and variable PARAMETERS to multiplex data to same buffer[shift], thus creating serial like output from an indicator.
//Calling indicator:
start()
{
data[0]=iCustom(symbol, timeframe, name, 0, 0, shift);
data[1]=iCustom(symbol, timeframe, name, 1, 0, shift);
data[2]=iCustom(symbol, timeframe, name, 2, 0, shift);
data[3]=iCustom(symbol, timeframe, name, 3, 0, shift);
}
..
..
//Responding indicator:
start()
{
if(parameter==0) OutputBuffer0[shift]=data[0];
if(parameter==1) OutputBuffer0[shift]=data[1];
if(parameter==2) OutputBuffer0[shift]=data[2];
if(parameter==3) OutputBuffer0[shift]=data[3];
}