A simpler attempt (that didn't work either) based on a suggestion of Alain Verleyen was:
#include <WinAPI\winuser.mqh> #define WM_COMMAND 0x0111 #define MT5_WMCMD_EXPERTS 32851 void OnStart() { int wHandle=(int)ChartGetInteger(0,CHART_WINDOW_HANDLE); long hMDI=GetParent(GetParent(wHandle)); Print(hMDI); PostMessageW(hMDI,WM_COMMAND,MT5_WMCMD_EXPERTS,0); }
A simpler attempt (that didn't work either) based on a suggestion of Alain Verleyen was:
What suggestion ?
What suggestion ?
I tried to solve my problem (unfortunately without success) using part of your answer in this post https://www.mql5.com/en/forum/38132. The part I used from your answer worked! I guess de handler is ok, and the problem is probably on the PostMessageW or on the defines
About this one, and advice on how to make it work?

- 2014.12.03
- www.mql5.com
I tried to solve my problem (unfortunately without success) using part of your answer in this post https://www.mql5.com/en/forum/38132. The part I used from your answer worked! I guess de handler is ok, and the problem is probably on the PostMessageW or on the defines
About this one, and advice on how to make it work?
I see.

- www.mql5.com
I see.
Fantastic! it's a completely different aproach (it doesn't use postmessage), but most important: it's works! Thanks Alain!
What suggestion ?
Hello,
How can I to know the flags for differents events using PostMessageW?
Example: I need open MQL5\logs using PostMessageW. I know for MT4 the flag is 35435, but Which it is for MT5?
Thanks!

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
I tried to convert to MQL5, but it didn't work:
Any suggestions or ideas?