Now I got a reply from Service Desk, and it's working!
Here it goes:
----------------------------------------
Yes, now when you globally declare variables of a
class or structure that have static members, you need to explicitly
declare those members to tell compiler in which order variables should
be initialized.
So, in your example, before the class declaration,
add the following line where you can initialize the static variable
with desired value (for example, 17.0):
Now I got a reply from Service Desk, and it's working!
Here it goes:
----------------------------------------
Yes, now when you globally declare variables of a
class or structure that have static members, you need to explicitly
declare those members to tell compiler in which order variables should
be initialized.
So, in your example, before the class declaration,
add the following line where you can initialize the static variable
with desired value (for example, 17.0):
Ok, so it's a change in the compiler. A little weird in my opinion, anyway thanks for the information.
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
Now I got a reply from Service Desk, and it's working!
Here it goes:
----------------------------------------
Yes, now when you globally declare variables of a class or structure that have static members, you need to explicitly declare those members to tell compiler in which order variables should be initialized.
So, in your example, before the class declaration, add the following line where you can initialize the static variable with desired value (for example, 17.0):
double CMM::m_percent=17.0; CMM mms;Now I got a reply from Service Desk, and it's working!
Here it goes:
----------------------------------------
Yes, now when you globally declare variables of a class or structure that have static members, you need to explicitly declare those members to tell compiler in which order variables should be initialized.
So, in your example, before the class declaration, add the following line where you can initialize the static variable with desired value (for example, 17.0):
Hello how about static array in a class ? no matter what I do there is still error...