What error 10027 actually reports
The code belongs to MqlTradeResult.retcode, not to the compiler error list and not necessarily to GetLastError. The trade server uses 10027 to report autotrading disabled by the client terminal.
Keep the request, the boolean returned by OrderSend, result.retcode, result.comment, and the symbol properties in the same log record. That separates a client-side request failure from a server-side rejection.
