Download MetaTrader 5
To add comments, please log in or register
Add our Facebook page to friends. Follow the latest news!
jackyO
10
jackyO 2010.11.09 18:23 

Hello,

I want to access USD/RMB and USD/MXN history data (.hst-files) from my MT4, and work with these data in an array of a MT5 indicator buffer. How can I accompolish that, please?

Jacky

Documentation on MQL5: Standard Constants, Enumerations and Structures / Indicator Constants / Indicators Lines
  • www.mql5.com
Standard Constants, Enumerations and Structures / Indicator Constants / Indicators Lines - Documentation on MQL5
Rashid Umarov
Admin
11709
Rashid Umarov 2010.11.10 08:44  

You can create your own indicator which is based on data from a file. See as example ColorCandlesDaily
jackyO
10
jackyO 2010.11.10 17:36  

Rosh, this is not it. ColorCandlesDaily doesn't access data form a file. It refers to the current symbol and redraws it in an indicator window, using a distinct candle color for each day.

I want to get history data into an indicator buffer. My current try, not finished yet: I am using the well known period_converter_opt.mp4 on a 1-min USDRMB chart and on a 1-min USDMXN chart, both GCI-Demo-MT4. These export the quotes to csv-files.

Hence MT5 cannot access that file, since MT4 can only write in its own files directory and MT5 can only read from its own files directory. So I wrote an AutoHotKey script that copies the MT4 csv files to the MT5 files directory, every time the filesize changes.

Now in MT5 I am currently into programming the OnInit section. It is supposed to open and read both csv file to a buffer array. Later I will extend my OnCalculate routine, so that it updates the array, every time the csv disk file changed, because it was copied again.

Oh, I am a newbee and things are hard work. I hope some professional reads this and just drops the two or three lines of code I need to accompolish what I want :-)

Documentation on MQL5: Standard Constants, Enumerations and Structures / Indicator Constants / Indicators Lines
  • www.mql5.com
Standard Constants, Enumerations and Structures / Indicator Constants / Indicators Lines - Documentation on MQL5
Rashid Umarov
Admin
11709
Rashid Umarov 2010.11.10 17:47  

You need:

That's all

Documentation on MQL5: Standard Constants, Enumerations and Structures / Indicator Constants / Indicators Lines
  • www.mql5.com
Standard Constants, Enumerations and Structures / Indicator Constants / Indicators Lines - Documentation on MQL5
okwh
1631
okwh 2010.11.11 05:18  

yes, but where to find the history files's data sturcture ?

data sturcture  of  those .hcc  file in Mql5 are not known ? 

 

Rashid Umarov
Admin
11709
Rashid Umarov 2010.11.11 08:53  
DxdCn:

yes, but where to find the history files's data sturcture ?

data sturcture  of  those .hcc  file in Mql5 are not known ? 

 

Topic starter asked about hst:

I want to access USD/RMB and USD/MXN history data (.hst-files) from my MT4, and work with these data in an array of a MT5 indicator buffer. How can I accompolish that, please?


/
To add comments, please log in or register