I am newbie... getting the following error "[" "Array required"

 

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);
   
  }
//+------------------------------------------------------------------+

 
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
Ask - Predefined Variables - MQL4 Reference
  • docs.mql4.com
Ask - Predefined Variables - MQL4 Reference