Hi there,
I wonder if it is possible to open position with custom indicator in MT5. I've created a trading "form" similar to "one click trading", but a bit advanced. Now when I try to open position with click on my button I get error 4752 "auto trading disabled by client". I have auto trading enabled in my terminal. Thanks for your help.
Hi
Indicators can't open trades, only EAs can. If you do have an EA and not an indicator, ensure auto trading is allowed in both the MT options and the EA options
Thanks both. Actually I already have coded an EA, which I use for automatic trading, but this EA doesn't put any objects to the chart, it just trades according to my trade strategy. So if I understand correctly, I could reprogram my existing EA, which would create the "advanced trade form" on the chart using objects. Would that work? The second option is that my existing "advance form" on indicator creates files on disk, which would afterwards be read by my EA, and place trades according to the contents of the files. But this option doesn't look handy. How would you do it?
I did it like this, changing a bit my existing EA: I've put code to generate the necessary objects for my advanced trade form on the OnInit event. Then I've added the OnChart event to the EA, like the one one indicators. And it works ok.
void OnChartEvent(const int id, const long &lparam, const double &dparam, const string &sparam) { if(id==CHARTEVENT_OBJECT_CLICK) { if (sparam == "BuyButton") { // logic to place position... } } }
........ The second option is that my existing "advance form" on indicator creates files on disk, which would afterwards be read by my EA, and place trades according to the contents of the files. But this option doesn't look handy. How would you do it?
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hi there,
I wonder if it is possible to open position with custom indicator in MT5. I've created a trading "form" similar to "one click trading", but a bit advanced. Now when I try to open position with click on my button I get error 4752 "auto trading disabled by client". I have auto trading enabled in my terminal. Thanks for your help.