lparam values with CHARTEVENT_CHART_CHANGE

 
Hello,

does anyone know what the lparam values mean after a CHARTEVENT_CHART_CHANGE event?
 
Marbo:
Hello,

does anyone know what the lparam values mean after a CHARTEVENT_CHART_CHANGE event?

Take a look here, its all layed out in the second table.


EDIT: in your case they mean nothing.
 
Dominik Egert #:

Take a look here, its all layed out in the second table.


EDIT: in your case they mean nothing.
I saw this table but I was curious what the values mean because I work with the CHARTEVENT_CHART_CHANGE and I thought they might be useful.
 
Marbo #I saw this table but I was curious what the values mean because I work with the CHARTEVENT_CHART_CHANGE and I thought they might be useful.

It is right there in the table as indicated in the documentation—none of the parameters are defined for that chart event.

Event

Value of the id parameter

Value of the lparam parameter

Value of the dparam parameter

Value of the sparam parameter

Event of change of the chart size or modification of chart properties through the Properties dialog

CHARTEVENT_CHART_CHANGE

Documentation on MQL5: Constants, Enumerations and Structures / Chart Constants / Chart Properties
Documentation on MQL5: Constants, Enumerations and Structures / Chart Constants / Chart Properties
  • www.mql5.com
Identifiers of ENUM_CHART_PROPERTY enumerations are used as parameters of functions for working with charts . The abbreviation of r/o in the ...
 
Fernando Carreiro #:

It is right there in the table as indicated in the documentation—none of the parameters are defined for that chart event.

Event

Value of the id parameter

Value of the lparam parameter

Value of the dparam parameter

Value of the sparam parameter

Event of change of the chart size or modification of chart properties through the Properties dialog

CHARTEVENT_CHART_CHANGE

I totally agree with you both. BUt this little function shows lparam values when CHARTEVENT_CHART_CHANGE is triggered and I was curious what they mean.

void OnChartEvent(const int id,
                  const long &lparam,
                  const double &dparam,
                  const string &sparam)
  {
//---
        if (id!=CHARTEVENT_MOUSE_MOVE) {
                Print(EnumToString((ENUM_CHART_EVENT)id));
                if (lparam>0) Print("lparam ",lparam);
                if (dparam>0) Print("dparam ",dparam);
                if (sparam!="") Print("sparam ",sparam);
        }
}
 
Marbo #I totally agree with you both. BUt this little function shows lparam values when CHARTEVENT_CHART_CHANGE is triggered and I was curious what they mean.

We cannot see your screen, so show us the log output as well.

However, undefined values are as the word states—undefined. The values that those variables contain can be remnants of what was in the memory before.

 
Fernando Carreiro #:

We cannot see your screen, so show us the log output as well.

However, undefined values are as the word states—undefined. The values that those variables contain can be remnants of what was in the memory before.

It shows always the same numbers 1, 16, 17, 34 and rarely 33 and 49. That's all I noticed. Depends on what you are doing with the chart. Scrolling, switching timeframes, change scale etc.

Maybe it's really some random data resulting from internal procedures. Like I said, I was just curious.