Is there any way to change the directory for writing/reading files from "Tester/Files" to "MQL/Files" when the Expert Advisor is working with these files during testing?
How do I calculate the lot volume in increments? If deposit =1000, lot = 0.1, deposit became 2000 lot = 0.2. That is, if the deposit is 1500 or 1700, the lot does not increase.
In this case you'd better use the FILE_COMMON flag and the files will be available both from the tester and the terminal. Only problems may occur when testing on the network. But personally I haven't tested it.
[in] Имя открываемого файла, может содержать подпапки. Если файл открывается для записи, то указанные подпапки будут созданы в случае их отсутствия. [in] значение, используемое в качестве разделителя в txt или csv-файле. Если для csv-файла разделитель не указан, то по умолчанию используется ";". Если для txt-файла разделитель не указан, то...
And why is everyone clinging to 0.1. Today a man wants 0.1, tomorrow he wants 0.5. You have to base it on the percentages. There is no point in being rigidly bound by intelligence.
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
Good afternoon,
Is there any way to change the directory for writing/reading files from "Tester/Files" to "MQL/Files" when the Expert Advisor is working with these files during testing?
Good afternoon,
Is it possible to change the reading/writing directory from "Tester/Files" to "MQL/Files" when Expert Advisor uses these files during testing?
With MQL - no way, only through WinAPI.
Thank you for your reply!
How do I calculate the lot volume in increments? If deposit =1000, lot = 0.1, deposit became 2000 lot = 0.2. That is, if the deposit is 1500 or 1700, the lot does not increase.
Not with MQL tools, only with WinAPI.
Thanks for the answer!
In this case you'd better use the FILE_COMMON flag and the files will be available both from the tester and the terminal. Only problems may occur when testing on the network. But personally I haven't tested it.
Taras Slobodyanik:
Let's do the math:
Deposit = 1,700. Divided by 1,000 we get 1.7 and rounded to the nearest integer on top, we get 2.
Multiply by 0.1 and the result is not what you want.
Apparently it is better to take rounding to the nearest lower integer MathFloor
No, no, with a deposit of 1100, the lot will be 0.11, and I need the lot not to increase up to 2000. How to specify a step =1000 in settings?
I have corrected it.
Although the principle is there, and this is a nuance
Let's do the math:
Deposit = 1,700. Divided by 1,000 we get 1.7 and rounded to the nearest whole number on top, we get 2.
Multiply by 0.1 and the result is not what you want.
Apparently it's better to round to the nearest lower integer MathFloor
or instead of 1000, use 1999.99 )
1000 and 0.1 are external variables.
Thank you, I did so:
I hope I put_depo ofint type correctly.