Returns the amount of free funds remaining after the specified position is opened at the current price on the current account. If there are not enough available funds, error 134 (ERR_NOT_ENOUGH_MONEY) will be generated.
Parameters:
symbol
-
Name of the financial instrument which should be traded.
cmd
-
The trade operation. Can be either OP_BUY or OP_SELL.
Good afternoon! Can you please tell me if it is possible to make the following operation: I open a trade with lot 2 with a target of 75 pips. When it reaches 50 pips, I want 50% of the initial lot to be closed. How can I do it without using manual intervention. Thank you in advance.
aaaaaaaaa: Good afternoon! Can you please tell me if it is possible to make the following operation: I open a trade with lot 2 with a target of 75 pips. When it reaches 50 pips, I want 50% of the initial lot to be closed. How can I do it without any manual intervention. Thank you in advance.
aaaaaaaaa: Good afternoon! Can you please tell me if it is possible to make the following operation: I open a trade with lot 2 with a target of 75 pips. When it reaches 50 pips, I want 50% of the initial lot to be closed. How can I do it without using manual intervention. Thank you in advance.
You can open 2 positions of 1 lot each. If you want to open only 1 position of 2 lots, you have to close it at 50 pips and open a new 1 lot position with a profit of 25 pips.
paladin80: You can open 2 positions of 1 lot. If you only want to open 1 position of 2 lots, you have to close it at 50 pips and open a new 1 lot position with a profit of 25 pips.
) Why do you do this? How about simply specifying a closing volume of 2 lots in orderclose?
I would like to get back to the issue of using iCustom. Here is a simple "Expert Advisor", which draws a Moving Average:
int init() {
return;
} // int init()int deinit() {
return;
}
int start() {
int MA_Period = 13;
int MA_Shift = 0;
int MA_Method = 0;
double MA = iCustom(NULL,0,"Moving Averages",MA_Period, MA_Shift, MA_Method, 0,0);
return;
} // int start() {
We run it in the Tester and see that the line itself appears only after the Tester finishes its work. - Why is the line not drawn during work, with every new bar? How to achieve this? Thank you!
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.
if(AccountFreeMarginCheck(Symbol(),OP_BUY,Lots)<=0|| GetLastError()==134) return;for some reason it's hyphenated.
You're answering off-topic.
Where are the professionals?
Here.
Passed on for you:
Where can I download a pure MT4???? terminal? I.e. without binding to a broker or brokerage company.
Who can suggest? I will be very grateful.
Where can I download a pure MT4???? terminal? I.e. without binding to a broker or brokerage company.
Who can suggest? I will be very grateful.
Can you please tell me if it is possible to make the following operation:
I open a trade with lot 2 with a target of 75 pips.
When it reaches 50 pips, I want 50% of the initial lot to be closed.
How can I do it without using manual intervention.
Thank you in advance.
Good afternoon!
Can you please tell me if it is possible to make the following operation:
I open a trade with lot 2 with a target of 75 pips.
When it reaches 50 pips, I want 50% of the initial lot to be closed.
How can I do it without any manual intervention.
Thank you in advance.
Good afternoon!
Can you please tell me if it is possible to make the following operation:
I open a trade with lot 2 with a target of 75 pips.
When it reaches 50 pips, I want 50% of the initial lot to be closed.
How can I do it without using manual intervention.
Thank you in advance.
You can open 2 positions of 1 lot. If you only want to open 1 position of 2 lots, you have to close it at 50 pips and open a new 1 lot position with a profit of 25 pips.
) Why do you do this? How about simply specifying a closing volume of 2 lots in orderclose?
I would like to get back to the issue of using iCustom.
Here is a simple "Expert Advisor", which draws a Moving Average:
We run it in the Tester and see that the line itself appears only after the Tester finishes its work.
- Why is the line not drawn during work, with every new bar? How to achieve this?
Thank you!