yster:
Try to use the MQL5InfoString(MQL5_PROGRAM_NAME)Hi,
WHat is the replaced function of WindowExpertName() in MQL5 ? How can i get expert name in MQL5?
Thanks
This s corrrect sintaxe:
string pgm_name = MQLInfoString(MQL_PROGRAM_NAME)
https://www.mql5.com/en/docs/check/mqlinfostring

Documentation on MQL5: Checkup / MQLInfoString
- www.mql5.com
Checkup / MQLInfoString - Reference on algorithmic/automated trading language for MetaTrader 5
fksalviano:
Did you realize that the previous answer had been made in 2010 ?? Regards. This s corrrect sintaxe:
string pgm_name = MQLInfoString(MQL_PROGRAM_NAME)
https://www.mql5.com/en/docs/check/mqlinfostring
Jose Francisco Casado Fernandez:
Did you realize that the previous answer had been made in 2010 ?? Regards.
Yes, but if tomorrow another person find this topic like i've found today, so will found the correct sintaxe
Did you realize that the previous answer had been made in 2010 ?? Regards.
However the return values of MQLInfoString(MQL_PROGRAM_NAME) do not match in MQL4 and MQL5.
While MQL4 returns the name of the file (without the extension), MQL5 returns a name assigned in IndicatorSetString(INDICATOR_SHORTNAME, ...).
if(MQLInfoString(MQL_PROGRAM_NAME)!="your eaname") return(0);
no extension!

You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Hi,
WHat is the replaced function of WindowExpertName() in MQL5 ? How can i get expert name in MQL5?
Thanks