![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
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
I think @Doerk Hilger meant his customers.
Yes, the users were meant, sorry :)
Dear all,
I am having similar kind of issue with tick value and tick size for XAUUSDx and my broker is ThinkMarkets. The specification is showed below. Please not the Contract Size is 100, Margin Currency is USD, Calculation is CFD Leverage and Tick size is 0.01 and Tick value is 0.01.
In meta trader 5, formula for calculating margin requirement if the value of ENUM_SYMBOL_CALC_MODE is SYMBOL_CALC_MODE_CFDLEVERAGE is as below:
SYMBOL_CALC_MODE_CFDLEVERAGE
CFD Leverage mode - calculation of margin and profit for CFD at leverage trading
Margin: (Lots * ContractSize * MarketPrice) / Leverage * Margin_Rate
Profit: (close_price-open_price) * Contract_Size * Lots
When I am using following code to calculate lot size requirement:
I am getting following output:
which is literally position size has to be 200lots for 50 points stop loss and 100$ risk. Which is not correct.
But when I run the same script on ICMarkets, I get the following output:
For ICMarkets, spec for XAUUSD is as follows: (Pls note Margin Currency is XAU and Calculation is Forex
Lotsize requirement for the first broker is 200 and for the second broker is 2.
My question is do I have to use contract size and if yes how am I going to use contract size to calculate the lot size required? Do i have to check SYMBOL_TRADE_CALC_MODE and SYMBOL_TRADE_CONTRACT_SIZE for calculating lot size as standard procedure for all symbols all the time?
Any help would be much appreciated!