Illustrative examples:
Money Fixed Risk
- www.mql5.com
An example for calculating the lot value in accordance with the risk per trade.
Yes, I'll go with the code that is there. My bad, this is what I get for making a habit of browsing on the phone...
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 to all,
as I understand it, first I have to include and declare the class
#include <Expert\Money\MoneyFixedRisk.mqh> CMoneyFixedRisk risk;
I have to define the percentage that I want to risk in the method
after that I expected the class to give me double values of lotsize that allow me to stay in that risk percentage, depending on whether I was planning on going short or long:
or
But it didn't seem to work in this code example:
It only produces zeros.
I was also having trouble finding the respective passage that I needed in the article on CodeBase and I wasn't sure if I should post it there.
So why does it only produce 0.0 lots?