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
#define MT_WMCMD_EXPERTS 32851 #define WM_COMMAND 0x0111 #define GA_ROOT 2 #include <WinAPI\winapi.mqh> //+------------------------------------------------------------------+ //| Toggle auto-trading button | //+------------------------------------------------------------------+ void AlgoTradingStatus(bool Enable) { bool Status = (bool) TerminalInfoInteger(TERMINAL_TRADE_ALLOWED); if(Enable != Status) { HANDLE hChart = (HANDLE) ChartGetInteger(ChartID(), CHART_WINDOW_HANDLE); PostMessageW(GetAncestor(hChart, GA_ROOT), WM_COMMAND, MT_WMCMD_EXPERTS, 0); } }
Thanks.
Hello,
Anyway to disable algo trading of current chart EA only?
Thank you
Just use ExpertRemove to remove the EA from that chart. It will be the same as disabling the auto trading.
Just use ExpertRemove to remove the EA from that chart. It will be the same as disabling the auto trading.
That would not work as what I was looking for is to just play and pause, There is not to re-attach after ExpertRemove().
Then code that. When in doubt, think!
Then code that. When in doubt, think!
That's an interesting approach though It did not serve the purpose, the goal was to disable trading for a EA without its source code, Sorry I did not mention that very clearly.
That's an interesting approach though It did not serve the purpose, the goal was to disable trading for a EA without its source code, Sorry I did not mention that very clearly.
hi , i have the same issue too
hi , i have the same issue too
What issue ? If you don't want an EA to trade, just don't run it.
Anything using DLL to play with the Algo Trading button or specific EA "Allow algo trading" is a bad idea.
hi , i have the same issue too