What MQL4 error 146 means
The official MQL4 runtime table names error 146 ERR_TRADE_CONTEXT_BUSY and defines it as “trade context is busy.” Another trade operation is still using the terminal trade context, so the current request cannot run yet.
The error number is evidence about one failed call, not a diagnosis of the whole EA. Read the API sentinel first, then call GetLastError immediately because that function returns the current _LastError value and resets it.
