Download MetaTrader 5

iOpen

To add comments, please log in or register
Learn operation principles of Trading Signals for MetaTrader.
mostafalotfi
185
mostafalotfi 2014.03.11 14:31 

Hello Guys

 

i decided to move from MQL4 to MQL5 , i have a small question

how can i have the below example in MQL5? 

              double Body=((iOpen(NULL,PERIOD_W1,1)-iClose(NULL,PERIOD_W1,1))/Point);

 

could you please introduce me a book fro MQL5? 

Alain Verleyen
Moderator
30736
Alain Verleyen 2014.03.11 14:39  
mostafalotfi:

Hello Guys

 

i decided to move from MQL4 to MQL5 , i have a small question

how can i have the below example in MQL5? 

 

could you please introduce me a book fro MQL5? 

See this article https://www.mql5.com/en/articles/81

Migrating from MQL4 to MQL5
Migrating from MQL4 to MQL5
  • 2010.05.17
  • Sergey Pavlov
  • www.mql5.com
This article is a quick guide to MQL4 language functions, it will help you to migrate your programs from MQL4 to MQL5. For each MQL4 function (except trading functions) the description and MQL5 implementation are presented, it allows you to reduce the conversion time significantly. For convenience, the MQL4 functions are divided into groups, similar to MQL4 Reference.
mostafalotfi
185
mostafalotfi 2014.03.21 18:22  

Hi Guys

 

may i ask you to help me with iOpen?

double iOpenMQL4(string symbol,int tf,int index)

{   
   if(index < 0) return(-1);
   double Arr[];
   ENUM_TIMEFRAMES timeframe=TFMigrate(tf);
   if(CopyOpen(symbol,timeframe, index, 1, Arr)>0) 
        return(Arr[0]);
   else return(-1);
}

 i cannot understand how can i use it :(

Alain Verleyen
Moderator
30736
Alain Verleyen 2014.03.21 18:56  
mostafalotfi:

Hi Guys

 

may i ask you to help me with iOpen?

 i cannot understand how can i use it :(

Sorry but I cannot understand what's your problem ? iOpenMQL4 is a function, you have to call it with the required parameters.
mostafalotfi
185
mostafalotfi 2014.03.21 22:30  
angevoyageur:
Sorry but I cannot understand what's your problem ? iOpenMQL4 is a function, you have to call it with the required parameters.
Hi , thanks i got it :D
To add comments, please log in or register