
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
I was using MqlTradeRequest and OrderSend() to open my positions. But now I am thinking of updating my code and to use CTrade and PositionOpen() instead.
But I have a couple of doubts about it. (Deviation, MagicNumber and How to handle errors).In the following code:
Is it properly structured? (Deviation and MagicNumber)
If an error occurs in the PositionOpen() function, is there a possibility that a misconfigured position will be opened? For example, without stop loss? I will need close it using PositionClose()?
Thank you so much!!