Trades placed with CTrade returning always 0 for the Result variables
After some testing I found that it was because I was doing it asynchronous. So i guess it was printing the variables before the trade was set. The problem I find with this is that my script will have to wait to the position to be placed for it to keep managin the orders.
Is it a bad practice if I do it sinchronous? Is there any other solution?
Thank you.
Is it a bad practice if I do it sinchronous? Is there any other solution?
Thank you.
I'm trying for the first time this class and followed this guide https://www.mql5.com/en/articles/481 . Problem is that after placing the order I need to get the ticket because I'm trying to manage the operations by myself. The problem is that even the operation is placed and it has a ticket, a price, volume, etc. When asking this information it returns me 0.
Here the code and the print out.
Thank you.