Ошибка 131 мт4

2009.10.27 22:49:11 2009.04.01 03:23 (777) YODJ EURCHF,M1: OrderSend()- Ошибка OP_BUY. op 1.50975000 sl 1.32780000 tp 1.51157000 lot 0.11000000 free margin 164043.29600000 err 131
2009.10.27 22:49:11 2009.04.01 03:23 (777) YODJ EURCHF,M1: OrderSend error 131
2009.10.27 22:49:11 2009.04.01 03:15 (777) YODJ EURCHF,M1: OrderSend()- Ошибка OP_BUY. op 1.50908000 sl 1.32713000 tp 1.51090000 lot 0.11000000 free margin 164043.29600000 err 131
2009.10.27 22:49:11 2009.04.01 03:15 (777) YODJ EURCHF,M1: OrderSend error 131
2009.10.27 22:49:11 2009.04.01 03:10 (777) YODJ EURCHF,M1: OrderSend()- Ошибка OP_BUY. op 1.50853000 sl 1.32658000 tp 1.51035000 lot 0.11000000 free margin 164043.29600000 err 131
2009.10.27 22:49:11 2009.04.01 03:10 (777) YODJ EURCHF,M1: OrderSend error 131
2009.10.27 22:49:11 2009.04.01 03:10 (777) YODJ EURCHF,M1: OrderSend()- Ошибка OP_BUY. op 1.50843000 sl 1.32648000 tp 1.51025000 lot 0.11000000 free margin 164043.29600000 err 131
2009.10.27 22:49:11 2009.04.01 03:10 (777) YODJ EURCHF,M1: OrderSend error 131
2009.10.27 22:49:11 2009.04.01 03:10 (777) YODJ EURCHF,M1: OrderSend()- Ошибка OP_BUY. op 1.50848000 sl 1.32653000 tp 1.51030000 lot 0.11000000 free margin 164043.29600000 err 131
2009.10.27 22:49:11 2009.04.01 03:10 (777) YODJ EURCHF,M1: OrderSend error 131
2009.10.27 22:49:11 2009.04.01 03:09 (777) YODJ EURCHF,M1: OrderSend()- Ошибка OP_BUY. op 1.50803000 sl 1.32608000 tp 1.50985000 lot 0.11000000 free margin 164043.29600000 err 131
2009.10.27 22:49:11 2009.04.01 03:09 (777) YODJ EURCHF,M1: OrderSend error 131
2009.10.27 22:49:11 2009.04.01 02:59 (777) YODJ EURCHF,M1: OrderSend()- Ошибка OP_BUY. op 1.50668000 sl 1.32472000 tp 1.50850000 lot 0.11000000 free margin 164043.29600000 err 131
2009.10.27 22:49:11 2009.04.01 02:59 (777) YODJ EURCHF,M1: OrderSend error 131
2009.10.27 22:49:11 2009.04.01 02:58 (777) YODJ EURCHF,M1: OrderSend()- Ошибка OP_BUY. op 1.50749000 sl 1.32553000 tp 1.50931000 lot 0.11000000 free margin 164043.29600000 err 131
2009.10.27 22:49:11 2009.04.01 02:58 (777) YODJ EURCHF,M1: OrderSend error 131
2009.10.27 22:49:11 2009.04.01 02:58 (777) YODJ EURCHF,M1: OrderSend()- Ошибка OP_BUY. op 1.50754000 sl 1.32558000 tp 1.50936000 lot 0.11000000 free margin 164043.29600000 err 131
2009.10.27 22:49:11 2009.04.01 02:58 (777) YODJ EURCHF,M1: OrderSend error 131
2009.10.27 22:49:11 2009.04.01 02:58 (777) YODJ EURCHF,M1: OrderSend()- Ошибка OP_BUY. op 1.50759000 sl 1.32563000 tp 1.50941000 lot 0.11000000 free margin 164043.29600000 err 131
2009.10.27 22:49:11 2009.04.01 02:58 (777) YODJ EURCHF,M1: OrderSend error 131
2009.10.27 22:49:11 2009.04.01 02:58 (777) YODJ EURCHF,M1: OrderSend()- Ошибка OP_BUY. op 1.50763000 sl 1.32567000 tp 1.50945000 lot 0.11000000 free margin 164043.29600000 err 131
2009.10.27 22:49:11 2009.04.01 02:58 (777) YODJ EURCHF,M1: OrderSend error 131
2009.10.27 22:49:11 2009.04.01 02:58 (777) YODJ EURCHF,M1: OrderSend()- Ошибка OP_BUY. op 1.50768000 sl 1.32572000 tp 1.50950000 lot 0.11000000 free margin 164043.29600000 err 131
2009.10.27 22:49:11 2009.04.01 02:58 (777) YODJ EURCHF,M1: OrderSend error 131

такая воот ошибка, не могу понять откуда берется….

нормалайз все значения, деньги есть (в приведенном логе видно), вообщем что то я в тупике :)) какие объемы? все выставленно нормально -(

What is MT4 Error 131?

The MT4 error 131 is an invalid volume OrderSend error code. It suggests that your Expert Advisor (EA) sends an order with an inappropriate trade volume to your broker’s server.

This error code may frequently appear during testing an MT4 EA, especially when there is an issue with the volume settings of your trading robot. Otherwise, it may happen due to a coding error of the expert advisor.

MT4 Error 131

The biggest problem with the OrderSend error 131 is it entirely disables your trading bot from executing backtests and fresh orders. It may happen for both paid and open-source EAs, because most of the time, it occurs due to a mismatch of volume calculation methods between the EA and the serving brokers.

So, your trading platform showing an error 131 doesn’t necessarily mean you need to abandon your EA or the broker. If there is a problem with the bot’s programming, you might need a few edits with the coding. Otherwise, you may check the volume settings of your expert advisor and fix the issue by only making a few changes.

In this guide, we explain the possible scenarios of encountering the error 131. Also, we discuss a couple of solutions for getting rid of the invalid volume OrderSend problem from your MT4 platform.

Why does MT4 error 131 happen?

An MT4 error 131 may happen due to the following reasons:

The EA is using an inappropriate volume figure

Most EAs calculate a trading volume based on the risk percentage, which is entirely acceptable and fair. But the problem occurs when the calculated figure comes with more than two digits. For instance, if it is a 0.01 or 0.11 lot, then there is no problem. But if it sends an order with a volume like 0.111 or 0.245, it’ll show the error code 131.

Issues with the volume settings

How your broker recognizes a trading volume may differ depending on your trading account types. Suppose your EA is configured for a micro account, and you’re using it for a standard account. In this case, your broker may read a 0.01 lot as 0.001, considering the figure is less than the minimum order limit. As a result, the order becomes invalid, and the system shows the same OrderSend error.

How to fix MT4 error 131?

Time needed: 5 minutes.

How to fix MT4 Invalid Volume OrderSend errors

  1. Adjust the volume settings

    If your broker fails to define the trading volume correctly, then insert the following codes to reset your volume settings:

    MT4 error 131 adjust-volume

    MODE_LOTSIZE – It determines the number of units an EA will consider to count as one standard lot. Typically, a standard-size lot equals 100,000 units.

    MODE_MINLOT – The minimum amount of trading volume you’ll use for executing an order. If your broker doesn’t accept 0.01 as the minimum lot size, consider replacing the value by 1.

    MODE_LOTSTEP – It sets the step size of your trading volume.

    MODE_MAXLOT – The maximum trading lot you can use for an order.

  2. Normalize the volume

    Alternatively, you can try normalizing the volume configuration of the EA with the following lines of code:

    MT4 Error 131 normalise volume

    This setting will keep the normalized volume lesser than the non-normalized value. For example, if the non-normalized volume is 0.1234, then the normalized volume will be 0.12.

    Also, you may encounter the MT4 error 131 during backtesting an EA. In that case, simply go offline and then try backtesting again.

OrderSend Error 131 is a very frequent problem that is usually encountered when testing MT4 expert advisors. What causes this error? It is called ERR_INVALID_TRADE_VOLUME in the MetaTrader 4 documentation. It means that your expert advisor (EA) is trying to send an order with invalid trade volume. At the absolute majority of the MT4 brokers, setting some EA to open an order with 0.123 lots volume will generate this error. But sometimes, it is generated when an EA created for mini or micro accounts is used on a standard account. If you stumble upon an OrderSend Error 131 during your strategy testing, you can quickly find the wrong settings of your EA. To do so, find the standard OnInit() (or init() in older versions of MT4) function inside your EA’s code and insert these lines of code there:

The output will be valid for the current chart’s trading symbol and for the trading account type you are currently logged in. The first line will tell you how many units there are in one lot of the current trading symbol (100,000 would mean a standard-sized lot). Remember that in your expert advisor’s log, this line will be first from the bottom. The second line will tell you the minimum amount of lots you can trade (this is the most usual error; you probably just need to fix the amount of lots your EA trades from 0.1 to 1). The third one will give the step size for the trade volume in lots. The fourth line will tell you the maximum number of lots that your EA can trade.

For example, a Standard trading account at Exness Forex broker generates the following information when the above-mentioned lines of code are executed on a EUR/USD chart:

Example Output of Min Lot, Max Lot, Lot Size, and Lot Step in MetaTrader 4

This means that 1 lot comprises 100,000 units (a standard size), the minimum trade volume is 0.01 lot (so, you can trade starting from $0.10 per pip in a dollar-based currency pair), the minimum trade volume step is also 0.01 lot (you can trade 0.33, 0.4 or 1.25 lot volumes, but you cannot send orders with 0.333 lot size), and the maximum volume you can use to open a position is 200 lots.

You can incorporate the MarketInfo() function at a more complex level into your EA, so that it could automatically check the allowed values and auto-correct the EA’s trade parameters. But if you don’t want to code much, you can just use the code above to find out the right values and correct the settings manually.

You can discuss your personal struggles with the OrderSend Error 131 problem on our forum if you are having trouble solving this issue on your own.

GetLastError() — функция, возвращающая коды ошибок. Кодовые константы ошибок определены
в файле stderror.mqh. Для вывода текстовых сообщений следует использовать функцию
ErrorDescription(), определенную в файле stdlib.mqh.

Константа Значение Описание
ERR_NO_ERROR 0 Нет ошибки
ERR_NO_RESULT 1 Нет ошибки, но результат неизвестен
ERR_COMMON_ERROR 2 Общая ошибка
ERR_INVALID_TRADE_PARAMETERS 3 Неправильные параметры
ERR_SERVER_BUSY 4 Торговый сервер занят
ERR_OLD_VERSION 5 Старая версия клиентского терминала
ERR_NO_CONNECTION 6 Нет связи с торговым сервером
ERR_NOT_ENOUGH_RIGHTS 7 Недостаточно прав
ERR_TOO_FREQUENT_REQUESTS 8 Слишком частые запросы
ERR_MALFUNCTIONAL_TRADE 9 Недопустимая операция нарушающая функционирование сервера
ERR_ACCOUNT_DISABLED 64 Счет заблокирован
ERR_INVALID_ACCOUNT 65 Неправильный номер счета
ERR_TRADE_TIMEOUT 128 Истек срок ожидания совершения сделки
ERR_INVALID_PRICE 129 Неправильная цена
ERR_INVALID_STOPS 130 Неправильные стопы
ERR_INVALID_TRADE_VOLUME 131 Неправильный объем
ERR_MARKET_CLOSED 132 Рынок закрыт
ERR_TRADE_DISABLED 133 Торговля запрещена
ERR_NOT_ENOUGH_MONEY 134 Недостаточно денег для совершения операции
ERR_PRICE_CHANGED 135 Цена изменилась
ERR_OFF_QUOTES 136 Нет цен
ERR_BROKER_BUSY 137 Брокер занят
ERR_REQUOTE 138 Новые цены
ERR_ORDER_LOCKED 139 Ордер заблокирован и уже обрабатывается
ERR_LONG_POSITIONS_ONLY_ALLOWED 140 Разрешена только покупка
ERR_TOO_MANY_REQUESTS 141 Слишком много запросов
ERR_TRADE_MODIFY_DENIED 145 Модификация запрещена, так как ордер слишком близок к рынку
ERR_TRADE_CONTEXT_BUSY 146 Подсистема торговли занята
ERR_TRADE_EXPIRATION_DENIED 147 Использование даты истечения ордера запрещено брокером
ERR_TRADE_TOO_MANY_ORDERS 148 Количество открытых и отложенных ордеров достигло предела, установленного брокером.
Константа Значение Описание
ERR_NO_MQLERROR 4000 Нет ошибки
ERR_WRONG_FUNCTION_POINTER 4001 Неправильный указатель функции
ERR_ARRAY_INDEX_OUT_OF_RANGE 4002 Индекс массива — вне диапазона
ERR_NO_MEMORY_FOR_FUNCTION_CALL_STACK 4003 Нет памяти для стека функций
ERR_RECURSIVE_STACK_OVERFLOW 4004 Переполнение стека после рекурсивного вызова
ERR_NOT_ENOUGH_STACK_FOR_PARAMETER 4005 На стеке нет памяти для передачи параметров
ERR_NO_MEMORY_FOR_PARAMETER_STRING 4006 Нет памяти для строкового параметра
ERR_NO_MEMORY_FOR_TEMP_STRING 4007 Нет памяти для временной строки
ERR_NOT_INITIALIZED_STRING 4008 Неинициализированная строка
ERR_NOT_INITIALIZED_ARRAYSTRING 4009 Неинициализированная строка в массиве
ERR_NO_MEMORY_FOR_ARRAYSTRING 4010 Нет памяти для строкового массива
ERR_TOO_LONG_STRING 4011 Слишком длинная строка
ERR_REMAINDER_FROM_ZERO_DIVIDE 4012 Остаток от деления на ноль
ERR_ZERO_DIVIDE 4013 Деление на ноль
ERR_UNKNOWN_COMMAND 4014 Неизвестная команда
ERR_WRONG_JUMP 4015 Неправильный переход
ERR_NOT_INITIALIZED_ARRAY 4016 Неинициализированный массив
ERR_DLL_CALLS_NOT_ALLOWED 4017 Вызовы DLL не разрешены
ERR_CANNOT_LOAD_LIBRARY 4018 Невозможно загрузить библиотеку
ERR_CANNOT_CALL_FUNCTION 4019 Невозможно вызвать функцию
ERR_EXTERNAL_EXPERT_CALLS_NOT_ALLOWED 4020 Вызовы внешних библиотечных функций не разрешены
ERR_NOT_ENOUGH_MEMORY_FOR_RETURNED_STRING 4021 Недостаточно памяти для строки, возвращаемой из функции
ERR_SYSTEM_BUSY 4022 Система занята
ERR_INVALID_FUNCTION_PARAMETERS_COUNT 4050 Неправильное количество параметров функции
ERR_INVALID_FUNCTION_PARAMETER_VALUE 4051 Недопустимое значение параметра функции
ERR_STRING_FUNCTION_INTERNAL_ERROR 4052 Внутренняя ошибка строковой функции
ERR_SOME_ARRAY_ERROR 4053 Ошибка массива
ERR_INCORRECT_SERIES_ARRAY_USING 4054 Неправильное использование массива-таймсерии
ERR_CUSTOM_INDICATOR_ERROR 4055 Ошибка пользовательского индикатора
ERR_INCOMPATIBLE_ARRAYS 4056 Массивы несовместимы
ERR_GLOBAL_VARIABLES_PROCESSING_ERROR 4057 Ошибка обработки глобальныех переменных
ERR_GLOBAL_VARIABLE_NOT_FOUND 4058 Глобальная переменная не обнаружена
ERR_FUNCTION_NOT_ALLOWED_IN_TESTING_MODE 4059 Функция не разрешена в тестовом режиме
ERR_FUNCTION_NOT_CONFIRMED 4060 Функция не подтверждена
ERR_SEND_MAIL_ERROR 4061 Ошибка отправки почты
ERR_STRING_PARAMETER_EXPECTED 4062 Ожидается параметр типа string
ERR_INTEGER_PARAMETER_EXPECTED 4063 Ожидается параметр типа integer
ERR_DOUBLE_PARAMETER_EXPECTED 4064 Ожидается параметр типа double
ERR_ARRAY_AS_PARAMETER_EXPECTED 4065 В качестве параметра ожидается массив
ERR_HISTORY_WILL_UPDATED 4066 Запрошенные исторические данные в состоянии обновления
ERR_TRADE_ERROR 4067 Ошибка при выполнении торговой операции
ERR_END_OF_FILE 4099 Конец файла
ERR_SOME_FILE_ERROR 4100 Ошибка при работе с файлом
ERR_WRONG_FILE_NAME 4101 Неправильное имя файла
ERR_TOO_MANY_OPENED_FILES 4102 Слишком много открытых файлов
ERR_CANNOT_OPEN_FILE 4103 Невозможно открыть файл
ERR_INCOMPATIBLE_ACCESS_TO_FILE 4104 Несовместимый режим доступа к файлу
ERR_NO_ORDER_SELECTED 4105 Ни один ордер не выбран
ERR_UNKNOWN_SYMBOL 4106 Неизвестный символ
ERR_INVALID_PRICE_PARAM 4107 Неправильный параметр цены для торговой функции
ERR_INVALID_TICKET 4108 Неверный номер тикета
ERR_TRADE_NOT_ALLOWED 4109 Торговля не разрешена
ERR_LONGS_NOT_ALLOWED 4110 Длинные позиции не разрешены
ERR_SHORTS_NOT_ALLOWED 4111 Короткие позиции не разрешены
ERR_OBJECT_ALREADY_EXISTS 4200 Объект уже существует
ERR_UNKNOWN_OBJECT_PROPERTY 4201 Запрошено неизвестное свойство объекта
ERR_OBJECT_DOES_NOT_EXIST 4202 Объект не существует
ERR_UNKNOWN_OBJECT_TYPE 4203 Неизвестный тип объекта
ERR_NO_OBJECT_NAME 4204 Нет имени объекта
ERR_OBJECT_COORDINATES_ERROR 4205 Ошибка координат объекта
ERR_NO_SPECIFIED_SUBWINDOW 4206 Не найдено указанное подокно
ERR_SOME_OBJECT_ERROR 4207 Ошибка при работе с объектом

Step 1 – Solve Mt4 Error Code 131

Is Mt4 Error Code 131 appearing? Would you like to safely and quickly eliminate close all positions which additionally can lead to a blue screen of death?

When you manually edit your Windows Registry trying to take away the invalid ordersend error 131 keys you’re taking a authentic chance. Unless you’ve got been adequately trained and experienced you’re in danger of disabling your computer system from working at all. You could bring about irreversible injury to your whole operating system. As very little as just 1 misplaced comma can preserve your Pc from even booting every one of the way by!

Troubleshooting close all positions mt4 Windows XP, Vista, 7, 8 & 10

Simply because this chance is so higher, we hugely suggest that you make use of a trusted registry cleaner plan like CCleaner (Microsoft Gold Partner Licensed). This system will scan and then fix any Mt4 Error Code 131 complications.

Registry cleaners automate the entire procedure of finding invalid registry entries and missing file references (including the Code error) likewise as any broken hyperlinks inside of your registry.

Issue with mt4 close all trades script

Backups are made immediately prior to each and every scan providing you with the choice of undoing any changes with just one click. This protects you against doable damaging your pc. Another advantage to these registry cleaners is that repaired registry errors will strengthen the speed and performance of one’s procedure drastically.

  • http://www.strategyquant.com/forum/topic/388-ordersend-error-131-and-error-opening-order131invalid-trade-volume/
  • https://www.mql5.com/en/forum/45360
  • https://docs.mql4.com/constants/errorswarnings/enum_trade_return_codes
  • https://forum.mql4.com/30702

Cautionary Note: Yet again, for those who are not an state-of-the-art consumer it’s very encouraged that you simply refrain from editing your Windows Registry manually. If you make even the smallest error within the Registry Editor it can result in you some serious issues that may even call for a brand new set up of Windows. Not all difficulties attributable to incorrect Registry Editor use are solvable.

Fixed: mt4 account number

Symptoms of Mt4 Error Code 131
“Mt4 Error Code 131” appears and crashes the energetic method window.
Your Personal computer routinely crashes with Mt4 Error Code 131 when running the exact same system.
“Mt4 Error Code 131” is shown.
Windows operates sluggishly and responds little by little to mouse or keyboard input.
Your computer periodically “freezes” for the number of seconds in a time.

Will cause of Mt4 Error Code 131

Corrupt obtain or incomplete set up of Windows Operating System software program.

Corruption in Windows registry from a new Windows Operating System-related application adjust (install or uninstall).

Virus or malware infection which has corrupted Windows method documents or Windows Operating System-related application data files.

Another method maliciously or mistakenly deleted Windows Operating System-related files.

Mistakes this sort of as “Mt4 Error Code 131” can be brought about by several different elements, so it really is important that you troubleshoot every of the achievable brings about to forestall it from recurring.

Simply click the beginning button.
Variety “command” inside the lookup box… Will not hit ENTER nonetheless!
Although keeping CTRL-Shift in your keyboard, hit ENTER.
You’re going to be prompted that has a authorization dialog box.
Click on Of course.
A black box will open having a blinking cursor.
Variety “regedit” and hit ENTER.
Within the Registry Editor, choose the ordersend error 131 connected key (eg. Windows Operating System) you wish to back again up.
Within the File menu, choose Export.
Inside the Preserve In list, pick out the folder in which you wish to save the Windows Operating System backup key.
Inside the File Title box, sort a reputation for the backup file, these types of as “Windows Operating System Backup”.
From the Export Vary box, ensure that “Selected branch” is selected.
Click on Help you save.
The file is then saved by using a .reg file extension.
You now use a backup within your close all positions mt4 related registry entry.

Solution to your metatrader close all positions problem

There are actually some manual registry editing measures that can not be talked about in this article due to the high chance involved for your laptop or computer method. If you want to understand more then check out the links below.

Additional Measures:

One. Conduct a Thorough Malware Scan

There’s a probability the Error Code 131 Mt4 error is relevant to some variety of walware infection. These infections are malicious and ready to corrupt or damage and possibly even delete your ActiveX Control Error files. Also, it’s attainable that your Mt4 Error Code 131 is actually connected to some element of that malicious plan itself.

2. Clean mt4 build 890 Disk Cleanup

The a lot more you employ your computer the extra it accumulates junk files. This comes from surfing, downloading packages, and any sort of usual computer system use. When you don’t clean the junk out occasionally and keep your program clean, it could turn into clogged and respond slowly. That is when you can encounter an 131 error because of possible conflicts or from overloading your hard drive.

Once you clean up these types of files using Disk Cleanup it could not just remedy Mt4 Error Code 131, but could also create a dramatic change in the computer’s efficiency.

Tip: While ‘Disk Cleanup’ is definitely an excellent built-in tool, it even now will not completely clean up close all discovered on your PC. There are numerous programs like Chrome, Firefox, Microsoft Office and more, that cannot be cleaned with ‘Disk Cleanup’.

Since the Disk Cleanup on Windows has its shortcomings it is extremely encouraged that you use a specialized sort of challenging drive cleanup and privacy safety application like CCleaner. This system can clean up your full pc. If you run this plan after each day (it could be set up to run instantly) you are able to be assured that your Pc is generally clean, often operating speedy, and always absolutely free of any Code error associated with your temporary files.

How Disk Cleanup can help script pending order mt4

1. Click your ‘Start’ Button.
2. Style ‘Command’ into your search box. (no ‘enter’ yet)
3. When holding down in your ‘CTRL-SHIFT’ important go ahead and hit ‘Enter’.
4. You will see a ‘permission dialogue’ box.
5. Click ‘Yes’
6. You will see a black box open up plus a blinking cursor.
7. Variety in ‘cleanmgr’. Hit ‘Enter’.
8. Now Disk Cleanup will start calculating the amount of occupied disk space you will be able to reclaim.
9. Now a ‘Disk Cleanup dialogue box’ seems. There will be a series of checkboxes for you personally to pick. Generally it will likely be the ‘Temporary Files’ that consider up the vast majority of your disk area.
10. Verify the boxes that you want cleaned. Click ‘OK’.

How to repair open position indicator mt4

3. System Restore can also be a worthwhile device if you ever get stuck and just desire to get back to a time when your computer system was working ideal. It will work without affecting your pics, paperwork, or other crucial information. You can discover this option with your User interface.

close all

Manufacturer

Device

Operating System


Mt4 Error Code 131


4 out of
5

based on
23 ratings.

 

Понравилась статья? Поделить с друзьями:
  • Ошибка 131 кпд
  • Ошибка 1310 microsoft office
  • Ошибка 131 ивеко дейли 35с15
  • Ошибка 131 змз 406
  • Ошибка 131 вольво 850