Download MetaTrader 5

FileOpenHistory(

To add comments, please log in or register
Download MetaTrader 5 for iPad and trade anywhere!
Yochanan Gerbi
608
Yochanan Gerbi 2010.12.14 09:45 

Hello freinds,

 

At MQL4 I hade FileOpenHistory(...),

and I changed it to:

FileOpen(C:\Program Files\Fxglobe ECN Metatrader 5.0\Bases\GoForex-Demo\history\...),

 

The compiler's response is:

many of: '\' - illegal escape sequence

 

What should I do:
 

Pawel Wojnarowski
685
Pawel Wojnarowski 2010.12.14 14:20  
crossy:

Hello freinds,

 

At MQL4 I hade FileOpenHistory(...),

and I changed it to:

FileOpen(C:\Program Files\Fxglobe ECN Metatrader 5.0\Bases\GoForex-Demo\history\...),

 

The compiler's response is:

many of: '\' - illegal escape sequence

 

What should I do:
 

 

Try replacing all \ with \\.
Slawa
Moderator
6839
Slawa 2010.12.14 15:22  
crossy:

 

What should I do:

You should read documentation https://www.mql5.com/en/docs/files
Documentation on MQL5: File Functions
  • www.mql5.com
File Functions - Documentation on MQL5
Pawel Wojnarowski
685
Pawel Wojnarowski 2010.12.14 16:01  
stringo:
You should read documentation https://www.mql5.com/en/docs/files
crossy: just like stringo has suggested, check the documentation. In https://www.mql5.com/en/docs/files/fileopen you can see an example code where you have \\ in the paths, not \.
Documentation on MQL5: File Functions / FileOpen
  • www.mql5.com
File Functions / FileOpen - Documentation on MQL5
Ilyas
1206
Ilyas 2010.12.14 17:20  
And don`t forget double quotes

Yochanan Gerbi
608
Yochanan Gerbi 2010.12.14 17:38  
mql5:
And don`t forget double quotes

Thank you freinds.
To add comments, please log in or register