[WARNING CLOSED!] Any newbie question, so as not to clutter up the forum. Professionals, don't go by. Can't go anywhere without you. - page 278
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Exactly what you need!
Can you tell me how to insert this code correctly into this grid?
(if I put it directly, the tester just stops at the opening of the first position)
I'm a little hesitant about this. I'm not even sure if it will work.
Gentlemen! What did I write wrong in the script....?
int start()
{
//----------------------------------
int i,counted_bars=IndicatorCounted();
i=Bars-counted_bars-1;
for(i=0; i<Bars; i++)
double a = Open[i]-Close[i];
//----------------------------------
if ( a > 0 )
{
Alert ("candle is BAD");
}
else
//----------------------------------
if ( a < 0 )
{
Alert ("the candle is BULLED");
}
//----
return(0);
}
//+---------------------------------
The task was to determine and output a message that Bar #1 is Bull or Bear. At the same time define and output a message for the subsequent Bar. Don't judge too severely)))
Everything below
"
double a = Open[i]-Close[i];
//----------------------------------
"
counts once for i equal to Bars-1.
Instead of for-cycle, put double a = Open[1]-Close[1]; since you need to make calculation for the first bar.
Everything below
"
double a = Open[i]-Close[i];
//----------------------------------
"
counts once for i equal to Bars-1.
Instead of for-cycle, put double a = Open[1]-Close[1]; if you need to do calculation for the first bar.
I've already tried it this way. Message was outputted every TIC for some reason?
Everything below
"
double a = Open[i]-Close[i];
//----------------------------------
"
counts once for i equal to Bars-1.
Instead of for-cycle, put double a = Open[1]-Close[1]; since you need to make calculation for the first bar.
Thank you! But why does it output the message now only once, and not every formed candle #1????
Thank you! But why does it output the message only once now, and not every formed candle #1????
So you said you have a script, make an indicator that will print on every tick, but perepeshite Alert on Comment and get tired of every tick to get Alerts or protect against triggering on every tick put.
So you said you have a script, make an indicator that will print on every tick, but move Alert on Comment and get tired of every tick to get Alerts or protect against triggering on every tick.
All figured it out, it works! Thank you again! Nicholas, and a question on Skype?
Got it, it's working! THANK YOU again!!! Nikolai, can I ask you a question on Skype?
Email me on Skype or in private.
No. That would not work. We have to set condition_2 in some other way
Could there be a function that simply detects that "there are no orders in the EA history yet"? - that would be enough