DCSACT:
AS I am trying tio compile the following code, I am getting error saying "[" array required. I dont know much about mql4. Pls help me figure out why it's showing this error and how to fix it.Thank you in advance.
void OnTick()
{
if(Close[0]>Close[1] & Ask[0]>Close[1]);
OrderSend(Symbol(),OP_BUY,0.01,Ask,100,25,30,0,0,0,clrNONE);
}
//+------------------------------------------------------------------+
Hello,
'Ask' doesn't need '[]'
DCSACT: AS I am trying tio compile the following code, I am getting error saying "[" array required. I dont know much about mql4. Pls help me figure out why it's showing this error and how to fix it.Thank you in advance.
The predefined variable Ask is not an array. Please follow the link and read the online documentation on it, which includes example code.

Ask - Predefined Variables - MQL4 Reference
- docs.mql4.com
Ask - Predefined Variables - MQL4 Reference

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
AS I am trying tio compile the following code, I am getting error saying "[" array required. I dont know much about mql4. Pls help me figure out why it's showing this error and how to fix it.Thank you in advance.
void OnTick()
{
if(Close[0]>Close[1] & Ask[0]>Close[1]);
OrderSend(Symbol(),OP_BUY,0.01,Ask,100,25,30,0,0,0,clrNONE);
}
//+------------------------------------------------------------------+