Risk depends on your initial stop loss and lot size.
Never used it, only the AccountFreeMarginCheck - Account Information - MQL4 Reference. Follow the stop out link above.
- You place the stop where it needs to be - where the reason for the trade is no longer valid. E.g. trading a support bounce the stop goes below the support.
- Account Balance * percent/100 = RISK = OrderLots * (|OrderOpenPrice - OrderStopLoss| * DeltaPerLot + CommissionPerLot) (Note OOP-OSL includes the SPREAD, and DeltaPerLot is usually around $10/pip but it takes account of the exchange rates of the pair vs. your account currency.)
- Do NOT use TickValue by itself - DeltaPerLot
- You must normalize lots properly and check against min and max.
- You must also check FreeMargin to avoid stop out
whroeder1:
Never used it, only the AccountFreeMarginCheck - Account Information - MQL4 Reference. Follow the stop out link above.
Never used it, only the AccountFreeMarginCheck - Account Information - MQL4 Reference. Follow the stop out link above.
Thank you whroeder1, for the every interesting insights. I will read up on them over the weekend.
Off topic:
I found a code that looks similar to this on the forum, I thought it was fairly use less, but I see a possible purpose for it now.
void OnInit() { ChartSetInteger(Chart_ID,CHART_SHOW_GRID,false); bool TF=ChartSetSymbolPeriod(chartid,charts,TIMEFRAME); if(AccountNumber()!=ALLOWED_ACCOUNT)MessageBox(Invalid,Account_Number_Wrong); if(AccountNumber()!=ALLOWED_ACCOUNT) return;
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Hello everyone,
I have started to write some account management code, but I don't understand what exactly AccountStopoutLevel means, at the moment ASOL = 20.0.
The information in the reference manual says "The value of the Stop Out level." Can someone please provide a more detailed explanation for me about it?