MetaTrader 5 error codes (296)
Every MetaTrader 5 error code in our register with the venue's own text. Codes with a link have a plain-English page with causes and fixes.
Check an order against MetaTrader 5 rules (free)
| Code | Name | Official text | Market |
|---|---|---|---|
| 0 | ERR_SUCCESS | The operation completed successfully | all |
| 4001 | ERR_INTERNAL_ERROR | Unexpected internal error | all |
| 4002 | ERR_WRONG_INTERNAL_PARAMETER | Wrong parameter in the inner call of the client terminal function | all |
| 4003 | ERR_INVALID_PARAMETER | Wrong parameter when calling the system function | all |
| 4004 | ERR_NOT_ENOUGH_MEMORY | Not enough memory to perform the system function | all |
| 4005 | ERR_STRUCT_WITHOBJECTS_ORCLASS | The structure contains objects of strings and/or dynamic arrays and/or structure of such objects and/or classes | all |
| 4006 | ERR_INVALID_ARRAY | Array of a wrong type, wrong size, or a damaged object of a dynamic array | all |
| 4007 | ERR_ARRAY_RESIZE_ERROR | Not enough memory for the relocation of an array, or an attempt to change the size of a static array | all |
| 4008 | ERR_STRING_RESIZE_ERROR | Not enough memory for the relocation of string | all |
| 4009 | ERR_NOTINITIALIZED_STRING | Not initialized string | all |
| 4010 | ERR_INVALID_DATETIME | Invalid date and/or time | all |
| 4011 | ERR_ARRAY_BAD_SIZE | Total amount of elements in the array cannot exceed 2147483647 | all |
| 4012 | ERR_INVALID_POINTER | Wrong pointer | all |
| 4013 | ERR_INVALID_POINTER_TYPE | Wrong type of pointer | all |
| 4014 | ERR_FUNCTION_NOT_ALLOWED | Function is not allowed for call | all |
| 4015 | ERR_RESOURCE_NAME_DUPLICATED | The names of the dynamic and the static resource match | all |
| 4016 | ERR_RESOURCE_NOT_FOUND | Resource with this name has not been found in EX5 | all |
| 4017 | ERR_RESOURCE_UNSUPPORTED_TYPE | Unsupported resource type or its size exceeds 16 Mb | all |
| 4018 | ERR_RESOURCE_NAME_IS_TOO_LONG | The resource name exceeds 63 characters | all |
| 4019 | ERR_MATH_OVERFLOW | Overflow occurred when calculating math function | all |
| 4020 | ERR_SLEEP_ERROR | Out of test end date after calling Sleep() | all |
| 4022 | ERR_PROGRAM_STOPPED | Test forcibly stopped from the outside. For example, optimization interrupted, visual testing window closed or testing agent stopped | all |
| 4023 | ERR_INVALID_TYPE | Invalid type | all |
| 4024 | ERR_INVALID_HANDLE | Invalid handle | all |
| 4025 | ERR_TOO_MANY_OBJECTS | Object pool filled out | all |
| 4101 | ERR_CHART_WRONG_ID | Wrong chart ID | all |
| 4102 | ERR_CHART_NO_REPLY | Chart does not respond | all |
| 4103 | ERR_CHART_NOT_FOUND | Chart not found | all |
| 4104 | ERR_CHART_NO_EXPERT | No Expert Advisor in the chart that could handle the event | all |
| 4105 | ERR_CHART_CANNOT_OPEN | Chart opening error | all |
| 4106 | ERR_CHART_CANNOT_CHANGE | Failed to change chart symbol and period | all |
| 4107 | ERR_CHART_WRONG_PARAMETER | Error value of the parameter for the function of working with charts | all |
| 4108 | ERR_CHART_CANNOT_CREATE_TIMER | Failed to create timer | all |
| 4109 | ERR_CHART_WRONG_PROPERTY | Wrong chart property ID | all |
| 4110 | ERR_CHART_SCREENSHOT_FAILED | Error creating screenshots | all |
| 4111 | ERR_CHART_NAVIGATE_FAILED | Error navigating through chart | all |
| 4112 | ERR_CHART_TEMPLATE_FAILED | Error applying template | all |
| 4113 | ERR_CHART_WINDOW_NOT_FOUND | Subwindow containing the indicator was not found | all |
| 4114 | ERR_CHART_INDICATOR_CANNOT_ADD | Error adding an indicator to chart | all |
| 4115 | ERR_CHART_INDICATOR_CANNOT_DEL | Error deleting an indicator from the chart | all |
| 4116 | ERR_CHART_INDICATOR_NOT_FOUND | Indicator not found on the specified chart | all |
| 4201 | ERR_OBJECT_ERROR | Error working with a graphical object | all |
| 4202 | ERR_OBJECT_NOT_FOUND | Graphical object was not found | all |
| 4203 | ERR_OBJECT_WRONG_PROPERTY | Wrong ID of a graphical object property | all |
| 4204 | ERR_OBJECT_GETDATE_FAILED | Unable to get date corresponding to the value | all |
| 4205 | ERR_OBJECT_GETVALUE_FAILED | Unable to get value corresponding to the date | all |
| 4301 | ERR_MARKET_UNKNOWN_SYMBOL | Unknown symbol | all |
| 4302 | ERR_MARKET_NOT_SELECTED | Symbol is not selected in MarketWatch | all |
| 4303 | ERR_MARKET_WRONG_PROPERTY | Wrong identifier of a symbol property | all |
| 4304 | ERR_MARKET_LASTTIME_UNKNOWN | Time of the last tick is not known (no ticks) | all |
| 4305 | ERR_MARKET_SELECT_ERROR | Error adding or deleting a symbol in MarketWatch | all |
| 4306 | ERR_MARKET_SELECT_LIMIT | Exceeded the limit of selected symbols in MarketWatch | all |
| 4307 | ERR_MARKET_SESSION_INDEX | Wrong session ID when calling the SymbolInfoSessionQuote/SymbolInfoSessionTrade function | all |
| 4401 | ERR_HISTORY_NOT_FOUND | Requested history not found | all |
| 4402 | ERR_HISTORY_WRONG_PROPERTY | Wrong ID of the history property | all |
| 4403 | ERR_HISTORY_TIMEOUT | Exceeded history request timeout | all |
| 4404 | ERR_HISTORY_BARS_LIMIT | Number of requested bars limited by terminal settings | all |
| 4405 | ERR_HISTORY_LOAD_ERRORS | Multiple errors when loading history | all |
| 4407 | ERR_HISTORY_SMALL_BUFFER | Receiving array is too small to store all requested data | all |
| 4501 | ERR_GLOBALVARIABLE_NOT_FOUND | Global variable of the client terminal is not found | all |
| 4502 | ERR_GLOBALVARIABLE_EXISTS | Global variable of the client terminal with the same name already exists | all |
| 4503 | ERR_GLOBALVARIABLE_NOT_MODIFIED | Global variables were not modified | all |
| 4504 | ERR_GLOBALVARIABLE_CANNOTREAD | Cannot read file with global variable values | all |
| 4505 | ERR_GLOBALVARIABLE_CANNOTWRITE | Cannot write file with global variable values | all |
| 4510 | ERR_MAIL_SEND_FAILED | Email sending failed | all |
| 4511 | ERR_PLAY_SOUND_FAILED | Sound playing failed | all |
| 4512 | ERR_MQL5_WRONG_PROPERTY | Wrong identifier of the program property | all |
| 4513 | ERR_TERMINAL_WRONG_PROPERTY | Wrong identifier of the terminal property | all |
| 4514 | ERR_FTP_SEND_FAILED | File sending via ftp failed | all |
| 4515 | ERR_NOTIFICATION_SEND_FAILED | Failed to send a notification | all |
| 4516 | ERR_NOTIFICATION_WRONG_PARAMETER | Invalid parameter for sending a notification – an empty string or NULL has been passed to the SendNotification() function | all |
| 4517 | ERR_NOTIFICATION_WRONG_SETTINGS | Wrong settings of notifications in the terminal (ID is not specified or permission is not set) | all |
| 4518 | ERR_NOTIFICATION_TOO_FREQUENT | Too frequent sending of notifications | all |
| 4519 | ERR_FTP_NOSERVER | FTP server is not specified | all |
| 4520 | ERR_FTP_NOLOGIN | FTP login is not specified | all |
| 4521 | ERR_FTP_FILE_ERROR | File not found in the MQL5\Files directory to send on FTP server | all |
| 4522 | ERR_FTP_CONNECT_FAILED | FTP connection failed | all |
| 4523 | ERR_FTP_CHANGEDIR | FTP path not found on server | all |
| 4601 | ERR_BUFFERS_NO_MEMORY | Not enough memory for the distribution of indicator buffers | all |
| 4602 | ERR_BUFFERS_WRONG_INDEX | Wrong indicator buffer index | all |
| 4603 | ERR_CUSTOM_WRONG_PROPERTY | Wrong ID of the custom indicator property | all |
| 4701 | ERR_ACCOUNT_WRONG_PROPERTY | Wrong account property ID | all |
| 4751 | ERR_TRADE_WRONG_PROPERTY | Wrong trade property ID | all |
| 4752 | ERR_TRADE_DISABLED | Trading by Expert Advisors prohibited | all |
| 4753 | ERR_TRADE_POSITION_NOT_FOUND | Position not found | all |
| 4754 | ERR_TRADE_ORDER_NOT_FOUND | Order not found | all |
| 4755 | ERR_TRADE_DEAL_NOT_FOUND | Deal not found | all |
| 4756 | ERR_TRADE_SEND_FAILED | Trade request sending failed | all |
| 4758 | ERR_TRADE_CALC_FAILED | Failed to calculate profit or margin | all |
| 4801 | ERR_INDICATOR_UNKNOWN_SYMBOL | Unknown symbol | all |
| 4802 | ERR_INDICATOR_CANNOT_CREATE | Indicator cannot be created | all |
| 4803 | ERR_INDICATOR_NO_MEMORY | Not enough memory to add the indicator | all |
| 4804 | ERR_INDICATOR_CANNOT_APPLY | The indicator cannot be applied to another indicator | all |
| 4805 | ERR_INDICATOR_CANNOT_ADD | Error applying an indicator to chart | all |
| 4806 | ERR_INDICATOR_DATA_NOT_FOUND | Requested data not found | all |
| 4807 | ERR_INDICATOR_WRONG_HANDLE | Wrong indicator handle | all |
| 4808 | ERR_INDICATOR_WRONG_PARAMETERS | Wrong number of parameters when creating an indicator | all |
| 4809 | ERR_INDICATOR_PARAMETERS_MISSING | No parameters when creating an indicator | all |
| 4810 | ERR_INDICATOR_CUSTOM_NAME | The first parameter in the array must be the name of the custom indicator | all |
| 4811 | ERR_INDICATOR_PARAMETER_TYPE | Invalid parameter type in the array when creating an indicator | all |
| 4812 | ERR_INDICATOR_WRONG_INDEX | Wrong index of the requested indicator buffer | all |
| 4901 | ERR_BOOKS_CANNOT_ADD | Depth Of Market can not be added | all |
| 4902 | ERR_BOOKS_CANNOT_DELETE | Depth Of Market can not be removed | all |
| 4903 | ERR_BOOKS_CANNOT_GET | The data from Depth Of Market can not be obtained | all |
| 4904 | ERR_BOOKS_CANNOT_SUBSCRIBE | Error in subscribing to receive new data from Depth Of Market | all |
| 5001 | ERR_TOO_MANY_FILES | More than 64 files cannot be opened at the same time | all |
| 5002 | ERR_WRONG_FILENAME | Invalid file name | all |
| 5003 | ERR_TOO_LONG_FILENAME | Too long file name | all |
| 5004 | ERR_CANNOT_OPEN_FILE | File opening error | all |
| 5005 | ERR_FILE_CACHEBUFFER_ERROR | Not enough memory for cache to read | all |
| 5006 | ERR_CANNOT_DELETE_FILE | File deleting error | all |
| 5007 | ERR_INVALID_FILEHANDLE | A file with this handle was closed, or was not opening at all | all |
| 5008 | ERR_WRONG_FILEHANDLE | Wrong file handle | all |
| 5009 | ERR_FILE_NOTTOWRITE | The file must be opened for writing | all |
| 5010 | ERR_FILE_NOTTOREAD | The file must be opened for reading | all |
| 5011 | ERR_FILE_NOTBIN | The file must be opened as a binary one | all |
| 5012 | ERR_FILE_NOTTXT | The file must be opened as a text | all |
| 5013 | ERR_FILE_NOTTXTORCSV | The file must be opened as a text or CSV | all |
| 5014 | ERR_FILE_NOTCSV | The file must be opened as CSV | all |
| 5015 | ERR_FILE_READERROR | File reading error | all |
| 5016 | ERR_FILE_BINSTRINGSIZE | String size must be specified, because the file is opened as binary | all |
| 5017 | ERR_INCOMPATIBLE_FILE | A text file must be for string arrays, for other arrays - binary | all |
| 5018 | ERR_FILE_IS_DIRECTORY | This is not a file, this is a directory | all |
| 5019 | ERR_FILE_NOT_EXIST | File does not exist | all |
| 5020 | ERR_FILE_CANNOT_REWRITE | File can not be rewritten | all |
| 5021 | ERR_WRONG_DIRECTORYNAME | Wrong directory name | all |
| 5022 | ERR_DIRECTORY_NOT_EXIST | Directory does not exist | all |
| 5023 | ERR_FILE_ISNOT_DIRECTORY | This is a file, not a directory | all |
| 5024 | ERR_CANNOT_DELETE_DIRECTORY | The directory cannot be removed | all |
| 5025 | ERR_CANNOT_CLEAN_DIRECTORY | Failed to clear the directory (probably one or more files are blocked and removal operation failed) | all |
| 5026 | ERR_FILE_WRITEERROR | Failed to write a resource to a file | all |
| 5027 | ERR_FILE_ENDOFFILE | Unable to read the next piece of data from a CSV file (FileReadString, FileReadNumber, FileReadDatetime, FileReadBool), since the end of file is reached | all |
| 5030 | ERR_NO_STRING_DATE | No date in the string | all |
| 5031 | ERR_WRONG_STRING_DATE | Wrong date in the string | all |
| 5032 | ERR_WRONG_STRING_TIME | Wrong time in the string | all |
| 5033 | ERR_STRING_TIME_ERROR | Error converting string to date | all |
| 5034 | ERR_STRING_OUT_OF_MEMORY | Not enough memory for the string | all |
| 5035 | ERR_STRING_SMALL_LEN | The string length is less than expected | all |
| 5036 | ERR_STRING_TOO_BIGNUMBER | Too large number, more than ULONG_MAX | all |
| 5037 | ERR_WRONG_FORMATSTRING | Invalid format string | all |
| 5038 | ERR_TOO_MANY_FORMATTERS | Amount of format specifiers more than the parameters | all |
| 5039 | ERR_TOO_MANY_PARAMETERS | Amount of parameters more than the format specifiers | all |
| 5040 | ERR_WRONG_STRING_PARAMETER | Damaged parameter of string type | all |
| 5041 | ERR_STRINGPOS_OUTOFRANGE | Position outside the string | all |
| 5042 | ERR_STRING_ZEROADDED | 0 added to the string end, a useless operation | all |
| 5043 | ERR_STRING_UNKNOWNTYPE | Unknown data type when converting to a string | all |
| 5044 | ERR_WRONG_STRING_OBJECT | Damaged string object | all |
| 5050 | ERR_INCOMPATIBLE_ARRAYS | Copying incompatible arrays. String array can be copied only to a string array, and a numeric array - in numeric array only | all |
| 5051 | ERR_SMALL_ASSERIES_ARRAY | The receiving array is declared as AS_SERIES, and it is of insufficient size | all |
| 5052 | ERR_SMALL_ARRAY | Too small array, the starting position is outside the array | all |
| 5053 | ERR_ZEROSIZE_ARRAY | An array of zero length | all |
| 5054 | ERR_NUMBER_ARRAYS_ONLY | Must be a numeric array | all |
| 5055 | ERR_ONEDIM_ARRAYS_ONLY | Must be a one-dimensional array | all |
| 5056 | ERR_SERIES_ARRAY | Timeseries cannot be used | all |
| 5057 | ERR_DOUBLE_ARRAY_ONLY | Must be an array of type double | all |
| 5058 | ERR_FLOAT_ARRAY_ONLY | Must be an array of type float | all |
| 5059 | ERR_LONG_ARRAY_ONLY | Must be an array of type long | all |
| 5060 | ERR_INT_ARRAY_ONLY | Must be an array of type int | all |
| 5061 | ERR_SHORT_ARRAY_ONLY | Must be an array of type short | all |
| 5062 | ERR_CHAR_ARRAY_ONLY | Must be an array of type char | all |
| 5063 | ERR_STRING_ARRAY_ONLY | String array only | all |
| 5100 | ERR_OPENCL_NOT_SUPPORTED | OpenCL functions are not supported on this computer | all |
| 5101 | ERR_OPENCL_INTERNAL | Internal error occurred when running OpenCL | all |
| 5102 | ERR_OPENCL_INVALID_HANDLE | Invalid OpenCL handle | all |
| 5103 | ERR_OPENCL_CONTEXT_CREATE | Error creating the OpenCL context | all |
| 5104 | ERR_OPENCL_QUEUE_CREATE | Failed to create a run queue in OpenCL | all |
| 5105 | ERR_OPENCL_PROGRAM_CREATE | Error occurred when compiling an OpenCL program | all |
| 5106 | ERR_OPENCL_TOO_LONG_KERNEL_NAME | Too long kernel name (OpenCL kernel) | all |
| 5107 | ERR_OPENCL_KERNEL_CREATE | Error creating an OpenCL kernel | all |
| 5108 | ERR_OPENCL_SET_KERNEL_PARAMETER | Error occurred when setting parameters for the OpenCL kernel | all |
| 5109 | ERR_OPENCL_EXECUTE | OpenCL program runtime error | all |
| 5110 | ERR_OPENCL_WRONG_BUFFER_SIZE | Invalid size of the OpenCL buffer | all |
| 5111 | ERR_OPENCL_WRONG_BUFFER_OFFSET | Invalid offset in the OpenCL buffer | all |
| 5112 | ERR_OPENCL_BUFFER_CREATE | Failed to create an OpenCL buffer | all |
| 5113 | ERR_OPENCL_TOO_MANY_OBJECTS | Too many OpenCL objects | all |
| 5114 | ERR_OPENCL_SELECTDEVICE | OpenCL device selection error | all |
| 5120 | ERR_DATABASE_INTERNAL | Internal database error | all |
| 5121 | ERR_DATABASE_INVALID_HANDLE | Invalid database handle | all |
| 5122 | ERR_DATABASE_TOO_MANY_OBJECTS | Exceeded the maximum acceptable number of Database objects | all |
| 5123 | ERR_DATABASE_CONNECT | Database connection error | all |
| 5124 | ERR_DATABASE_EXECUTE | Request execution error | all |
| 5125 | ERR_DATABASE_PREPARE | Request generation error | all |
| 5126 | ERR_DATABASE_NO_MORE_DATA | No more data to read | all |
| 5127 | ERR_DATABASE_STEP | Failed to move to the next request entry | all |
| 5128 | ERR_DATABASE_NOT_READY | Data for reading request results are not ready yet | all |
| 5129 | ERR_DATABASE_BIND_PARAMETERS | Failed to auto substitute parameters to an SQL request | all |
| 5200 | ERR_WEBREQUEST_INVALID_ADDRESS | Invalid URL | all |
| 5201 | ERR_WEBREQUEST_CONNECT_FAILED | Failed to connect to specified URL | all |
| 5202 | ERR_WEBREQUEST_TIMEOUT | Timeout exceeded | all |
| 5203 | ERR_WEBREQUEST_REQUEST_FAILED | HTTP request failed | all |
| 5270 | ERR_NETSOCKET_INVALIDHANDLE | Invalid socket handle passed to function | all |
| 5271 | ERR_NETSOCKET_TOO_MANY_OPENED | Too many open sockets (max 128) | all |
| 5272 | ERR_NETSOCKET_CANNOT_CONNECT | Failed to connect to remote host | all |
| 5273 | ERR_NETSOCKET_IO_ERROR | Failed to send/receive data from socket | all |
| 5274 | ERR_NETSOCKET_HANDSHAKE_FAILED | Failed to establish secure connection (TLS Handshake) | all |
| 5275 | ERR_NETSOCKET_NO_CERTIFICATE | No data on certificate protecting the connection | all |
| 5300 | ERR_NOT_CUSTOM_SYMBOL | A custom symbol must be specified | all |
| 5301 | ERR_CUSTOM_SYMBOL_WRONG_NAME | The name of the custom symbol is invalid. The symbol name can only contain Latin letters without punctuation, spaces or special characters (may only contain "." | all |
| 5302 | ERR_CUSTOM_SYMBOL_NAME_LONG | The name of the custom symbol is too long. The length of the symbol name must not exceed 32 characters including the ending 0 character | all |
| 5303 | ERR_CUSTOM_SYMBOL_PATH_LONG | The path of the custom symbol is too long. The path length should not exceed 128 characters including "Custom\\", the symbol name, group separators and the endi | all |
| 5304 | ERR_CUSTOM_SYMBOL_EXIST | A custom symbol with the same name already exists | all |
| 5305 | ERR_CUSTOM_SYMBOL_ERROR | Error occurred while creating, deleting or changing the custom symbol | all |
| 5306 | ERR_CUSTOM_SYMBOL_SELECTED | You are trying to delete a custom symbol selected in Market Watch | all |
| 5307 | ERR_CUSTOM_SYMBOL_PROPERTY_WRONG | An invalid custom symbol property | all |
| 5308 | ERR_CUSTOM_SYMBOL_PARAMETER_ERROR | A wrong parameter while setting the property of a custom symbol | all |
| 5309 | ERR_CUSTOM_SYMBOL_PARAMETER_LONG | A too long string parameter while setting the property of a custom symbol | all |
| 5310 | ERR_CUSTOM_TICKS_WRONG_ORDER | Ticks in the array are not arranged in the order of time | all |
| 5400 | ERR_CALENDAR_MORE_DATA | Array size is insufficient for receiving descriptions of all values | all |
| 5401 | ERR_CALENDAR_TIMEOUT | Request time limit exceeded | all |
| 5402 | ERR_CALENDAR_NO_DATA | Country is not found | all |
| 5601 | ERR_DATABASE_ERROR | Generic error | all |
| 5602 | ERR_DATABASE_LOGIC | SQLite internal logic error | all |
| 5603 | ERR_DATABASE_PERM | Access denied | all |
| 5604 | ERR_DATABASE_ABORT | Callback routine requested abort | all |
| 5605 | ERR_DATABASE_BUSY | Database file locked | all |
| 5606 | ERR_DATABASE_LOCKED | Database table locked | all |
| 5607 | ERR_DATABASE_NOMEM | Insufficient memory for completing operation | all |
| 5608 | ERR_DATABASE_READONLY | Attempt to write to readonly database | all |
| 5609 | ERR_DATABASE_INTERRUPT | Operation terminated by sqlite3_interrupt() | all |
| 5610 | ERR_DATABASE_IOERR | Disk I/O error | all |
| 5611 | ERR_DATABASE_CORRUPT | Database disk image corrupted | all |
| 5612 | ERR_DATABASE_NOTFOUND | Unknown operation code in sqlite3_file_control() | all |
| 5613 | ERR_DATABASE_FULL | Insertion failed because database is full | all |
| 5614 | ERR_DATABASE_CANTOPEN | Unable to open the database file | all |
| 5615 | ERR_DATABASE_PROTOCOL | Database lock protocol error | all |
| 5616 | ERR_DATABASE_EMPTY | Internal use only | all |
| 5617 | ERR_DATABASE_SCHEMA | Database schema changed | all |
| 5618 | ERR_DATABASE_TOOBIG | String or BLOB exceeds size limit | all |
| 5619 | ERR_DATABASE_CONSTRAINT | Abort due to constraint violation | all |
| 5620 | ERR_DATABASE_MISMATCH | Data type mismatch | all |
| 5621 | ERR_DATABASE_MISUSE | Library used incorrectly | all |
| 5622 | ERR_DATABASE_NOLFS | Uses OS features not supported on host | all |
| 5623 | ERR_DATABASE_AUTH | Authorization denied | all |
| 5624 | ERR_DATABASE_FORMAT | Not used | all |
| 5625 | ERR_DATABASE_RANGE | Bind parameter error, incorrect index | all |
| 5626 | ERR_DATABASE_NOTADB | File opened that is not database file | all |
| 5700 | ERR_MATRIX_INTERNAL | Internal error of the matrix/vector executing subsystem | all |
| 5701 | ERR_MATRIX_NOT_INITIALIZED | Matrix/vector not initialized | all |
| 5702 | ERR_MATRIX_INCONSISTENT | Inconsistent size of matrices/vectors in operation | all |
| 5703 | ERR_MATRIX_INVALID_SIZE | Invalid matrix/vector size | all |
| 5704 | ERR_MATRIX_INVALID_TYPE | Invalid matrix/vector type | all |
| 5705 | ERR_MATRIX_FUNC_NOT_ALLOWED | Function not available for this matrix/vector | all |
| 5706 | ERR_MATRIX_CONTAINS_NAN | Matrix/vector contains non-numbers (Nan/Inf) | all |
| 5707 | ERR_MATRIX_OPENBLAS | Error during execution of an OpenBLAS function | all |
| 5708 | ERR_MATRIX_OPENBLAS_PARAMETER | Invalid parameter of an OpenBLAS function | all |
| 5800 | ERR_ONNX_INTERNAL | ONNX internal error | all |
| 5801 | ERR_ONNX_NOT_INITIALIZED | ONNX Runtime API initialization error | all |
| 5802 | ERR_ONNX_NOT_SUPPORTED | Property or value not supported by MQL5 | all |
| 5803 | ERR_ONNX_RUN_FAILED | ONNX runtime API run error | all |
| 5804 | ERR_ONNX_INVALID_PARAMETERS_COUNT | Invalid number of parameters passed to OnnxRun | all |
| 5805 | ERR_ONNX_INVALID_PARAMETER | Invalid parameter value | all |
| 5806 | ERR_ONNX_INVALID_PARAMETER_TYPE | Invalid parameter type | all |
| 5807 | ERR_ONNX_INVALID_PARAMETER_SIZE | Invalid parameter size | all |
| 5808 | ERR_ONNX_WRONG_DIMENSION | Tensor dimension not set or invalid | all |
| 10004 | TRADE_RETCODE_REQUOTE | Requote | all |
| 10006 | TRADE_RETCODE_REJECT | Request rejected | all |
| 10007 | TRADE_RETCODE_CANCEL | Request canceled by trader | all |
| 10008 | TRADE_RETCODE_PLACED | Order placed | all |
| 10009 | TRADE_RETCODE_DONE | Request completed | all |
| 10010 | TRADE_RETCODE_DONE_PARTIAL | Only part of the request was completed | all |
| 10011 | TRADE_RETCODE_ERROR | Request processing error | all |
| 10012 | TRADE_RETCODE_TIMEOUT | Request canceled by timeout | all |
| 10013 | TRADE_RETCODE_INVALID | Invalid request | all |
| 10014 | TRADE_RETCODE_INVALID_VOLUME | Invalid volume in the request | all |
| 10015 | TRADE_RETCODE_INVALID_PRICE | Invalid price in the request | all |
| 10016 | TRADE_RETCODE_INVALID_STOPS | Invalid stops in the request | all |
| 10017 | TRADE_RETCODE_TRADE_DISABLED | Trade is disabled | all |
| 10018 | TRADE_RETCODE_MARKET_CLOSED | Market is closed | all |
| 10019 | TRADE_RETCODE_NO_MONEY | There is not enough money to complete the request | all |
| 10020 | TRADE_RETCODE_PRICE_CHANGED | Prices changed | all |
| 10021 | TRADE_RETCODE_PRICE_OFF | There are no quotes to process the request | all |
| 10022 | TRADE_RETCODE_INVALID_EXPIRATION | Invalid order expiration date in the request | all |
| 10023 | TRADE_RETCODE_ORDER_CHANGED | Order state changed | all |
| 10024 | TRADE_RETCODE_TOO_MANY_REQUESTS | Too frequent requests | all |
| 10025 | TRADE_RETCODE_NO_CHANGES | No changes in request | all |
| 10026 | TRADE_RETCODE_SERVER_DISABLES_AT | Autotrading disabled by server | all |
| 10027 | TRADE_RETCODE_CLIENT_DISABLES_AT | Autotrading disabled by client terminal | all |
| 10028 | TRADE_RETCODE_LOCKED | Request locked for processing | all |
| 10029 | TRADE_RETCODE_FROZEN | Order or position frozen | all |
| 10030 | TRADE_RETCODE_INVALID_FILL | Invalid order filling type | all |
| 10031 | TRADE_RETCODE_CONNECTION | No connection with the trade server | all |
| 10032 | TRADE_RETCODE_ONLY_REAL | Operation is allowed only for live accounts | all |
| 10033 | TRADE_RETCODE_LIMIT_ORDERS | The number of pending orders has reached the limit | all |
| 10034 | TRADE_RETCODE_LIMIT_VOLUME | The volume of orders and positions for the symbol has reached the limit | all |
| 10035 | TRADE_RETCODE_INVALID_ORDER | Incorrect or prohibited order type | all |
| 10036 | TRADE_RETCODE_POSITION_CLOSED | Position with the specified POSITION_IDENTIFIER has already been closed | all |
| 10038 | TRADE_RETCODE_INVALID_CLOSE_VOLUME | A close volume exceeds the current position volume | all |
| 10039 | TRADE_RETCODE_CLOSE_ORDER_EXIST | A close order already exists for a specified position. This may happen when working in the hedging system: when attempting to close a position with an opposite | all |
| 10040 | TRADE_RETCODE_LIMIT_POSITIONS | The number of open positions simultaneously present on an account can be limited by the server settings. After a limit is reached, the server returns the TRADE_ | all |
| 10041 | TRADE_RETCODE_REJECT_CANCEL | The pending order activation request is rejected, the order is canceled | all |
| 10042 | TRADE_RETCODE_LONG_ONLY | The request is rejected, because the " Only long positions are allowed " rule is set for the symbol ( POSITION_TYPE_BUY ) | all |
| 10043 | TRADE_RETCODE_SHORT_ONLY | The request is rejected, because the " Only short positions are allowed " rule is set for the symbol ( POSITION_TYPE_SELL ) | all |
| 10044 | TRADE_RETCODE_CLOSE_ONLY | The request is rejected, because the " Only position closing is allowed " rule is set for the symbol | all |
| 10045 | TRADE_RETCODE_FIFO_CLOSE | The request is rejected, because " Position closing is allowed only by FIFO rule " flag is set for the trading account ( ACCOUNT_FIFO_CLOSE =true) | all |
| 10046 | TRADE_RETCODE_HEDGE_PROHIBITED | The request is rejected, because the " Opposite positions on a single symbol are disabled " rule is set for the trading account. For example, if the account has | all |
| 65536 | ERR_USER_ERROR_FIRST | User defined errors start with this code | all |
This page explains an error message. It is information for developers, not financial advice and not a recommendation to trade. Codes and texts come from the venue's official documentation on the date shown; venues change them, so check the source before relying on it. Register built 2026-11-28.