Where can I get those Data (High / Low)?

 

Hi everyone,


can someone tell me where I can get exactly this 2 Data showed in the Graf of the EMA? I try to get Highest and Lowest but have every time a big difference to those displayed in the screenshot.

Thank you,

Jérôme

 
jerome77 :

Hi everyone,


can someone tell me where I can get exactly this 2 Data showed in the Graf of the EMA? I try to get Highest and Lowest but have every time a big difference to those displayed in the screenshot.

Thank you,

Jérôme

Here is an example (here the subwindow number is taken '1')

 //+------------------------------------------------------------------+
 //|                                                     Script 1.mq5 |
 //|                        Copyright 2020, MetaQuotes Software Corp. |
 //|                                             https://www.mql5.com |
 //+------------------------------------------------------------------+
 #property copyright "Copyright 2020, MetaQuotes Software Corp."
 #property link        "https://www.mql5.com"
 #property version    "1.00"
 //---
 //+------------------------------------------------------------------+
 //| Script program start function                                    |
 //+------------------------------------------------------------------+
 void OnStart ()
  {
   Print ( "CHART_PRICE_MAX " , ChartGetDouble ( 0 , CHART_PRICE_MAX , 1 ));
   Print ( "CHART_PRICE_MIN " , ChartGetDouble ( 0 , CHART_PRICE_MIN , 1 ));
  }


Indicator window:


The result of the script:

2021.03.01 11:21:56.018 Script 1 (EURUSD,D1)    CHART_PRICE_MAX 0.011073445
2021.03.01 11:21:56.018 Script 1 (EURUSD,D1)    CHART_PRICE_MIN -0.004600345
Files:
Script_1.mq5  2 kb
 
Vladimir Karputov:

Here is an example (here the subwindow number is taken '1')


Indicator window:


The result of the script:

HI Vladimir,

Hey Thank you very much for your answer I will try your code!


best regards,

Jérôme

 

HI,

I will try in English to explain my problem with Chartgetdouble.

I'm practically terminated in developing my EA and I see a big problem using Chartgetdouble! If I activate my robot on several pairs so I will have several Tab open. Now those 2 values Chart_Price_Max and Min on the chart:

   Print ( "CHART_PRICE_MAX " , ChartGetDouble ( 0 , CHART_PRICE_MAX , 1 ));
   Print ( "CHART_PRICE_MIN " , ChartGetDouble ( 0 , CHART_PRICE_MIN , 1 ));

are not refreshing and get complete wrong data or stucks if this tab is not in the forderground. So i can have my robot working only on 1 pair that works but as soon i have it on more than 1 tab i have after a few hours/days complete wrong min and max data?!!? If i activate then the Tab (Click on the Tab) with wrong data so that it's again in the forderground it will refresh the data after 2-3 seconds but if I don't activate the window it's still works with wrong data!

So when I using this and the Tab is iworking in the background i will have complete wrong data :-(

Can someone Help me?

 
jerome77 :

HI,

I will try in English to explain my problem with Chartgetdouble.

I'm practically terminated in developing my EA and I see a big problem using Chartgetdouble! If I activate my robot on several pairs so I will have several Tab open. Now those 2 values Chart_Price_Max and Min on the chart:

are not refreshing and get complete wrong data or stucks if this tab is not in the forderground. So i can have my robot working only on 1 pair that works but as soon i have it on more than 1 tab i have after a few hours/days complete wrong min and max data?!!? If i activate then the Tab (Click on the Tab) with wrong data so that it's again in the forderground it will refresh the data after 2-3 seconds but if I don't activate the window it's still works with wrong data!

So when I using this and the Tab is iworking in the background i will have complete wrong data :-(

Can someone Help me?

You need to keep in mind how the Windows operating system works. The name "Windows" is not accidental. While you are looking at the window (chart window) - you see it in expanded form, as soon as the window loses focus, the window is minimized.

 
Vladimir Karputov:

You need to keep in mind how the Windows operating system works. The name "Windows" is not accidental. While you are looking at the window (chart window) - you see it in expanded form, as soon as the window loses focus, the window is minimized.

HI Vladimi,

Thank you for your answer!

So if I want to get my robots working on several pairs I need 1 computer for each pair?I can only open 1 instance of Mt5 so ...hmm okay.

Is there a way to have those 2 value but by calculation? I thing the zoom is here also very important but do you know ho I can calculate them?

Thank you very much Vladimir I really apreciate your Help!

Best,

Jérôme

Reason: