From the documentation:
In case equity is not enough for maintaining open orders, the Stop Out situation, i.e. forced closing occurs. The minimum margin level at which Stop Out occurs can be set in percentage or in monetary terms. To find out the mode set for the account use the ENUM_ACCOUNT_STOPOUT_MODE enumeration.
Identifier | Description |
---|---|
ACCOUNT_STOPOUT_MODE_PERCENT | Account stop out mode in percents |
ACCOUNT_STOPOUT_MODE_MONEY | Account stop out mode in money |
"stopoutmode" variable in your code describes what is in the "margin_call" variable - percent or money amount.
BTW - you shortened EnumToString by using format "%.2s" - remove ".2"
- docs.mql4.com
From the documentation:
"stopoutmode" variable in your code describes what is in the "margin_call" variable - percent or money amount.
BTW - you shortened EnumToString by using format "%.2s" - remove ".2"
Thank you..but still....percent of what? call_level is 100 in my case, so it is 100% of what? Thank you
Thank you..but still....percent of what? call_level is 100 in my case, so it is 100% of what? Thank you
For percent it should be a margin level.
AccountEquity() / AccountMargin() * 100.0
That's the number you see as percentage on the bottom of the terminal window
There should be a margin call when margin level drops below percent or amount that is returned when you read ACCOUNT_MARGIN_SO_CALL.
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hello guys!
Kndly advice on the below:
I suppose Stopout mode will be percent. But I dont understand about ACCOUNT_MARGIN_SO_CALL. If stopmode will be percent, then margin call will be also percent, but from what? I belive that this result I get of " 100" is percentage, but do not understand from what it is . Thanks !!