Forum

Can't figure out why I'm getting an invalid request on my sell stop order.

Here's my code const double myVol = 0.1 ; ulong myTicket = 0 ; MqlTradeRequest request = {}; MqlTradeResult result = {}; ulong SendTradeRequest() { if ( OrderSend (request, result)) { return result.order; } else { Print ( "Error: " , GetLastError ()); return 0 ; }

Can you recommend some guides for simple EAs with best practices?

Hi, I'm familiar with C++ and have done a few projects with it. I want to learn how to write a simple script that places and order (O1) with a take profit and stop loss, and then, based on the what happens to O1 to place an O2 also with a take profit and a stop loss. Thank you