Try to find and modify all "OrderSend" functions in EA... Add "Lots" variable...
OrderSend(Symbol(),OP_BUY,Lots,Ask,3,Ask-25*Point,Ask+25*Point,"My order #2",16384,0,Green);
Diam0nd:
To start off, I am a beginner MQL programmer. Now, here goes a beginner question.
To start off, I am a beginner MQL programmer. Now, here goes a beginner question.
I have a variable defined in my EA:
extern double Lots = 0.1;
However, when the EA trades, it uses 1.0 lots, even though the 0.1 is set under variable above. Could anyone please be so kind to explain me how do I make sure that EA uses the lot size I set in the variable? Is there any special code I need to add to my expert?
Thanks in advance,
Diam0nd.raff1410:
Try to find and modify all "OrderSend" functions in EA... Add "Lots" variable... OrderSend(Symbol(),OP_BUY,Lots,Ask,3,Ask-25*Point,Ask+25*Point,"My order #2",16384,0,Green);
Try to find and modify all "OrderSend" functions in EA... Add "Lots" variable... OrderSend(Symbol(),OP_BUY,Lots,Ask,3,Ask-25*Point,Ask+25*Point,"My order #2",16384,0,Green);
Superb! Thanks so much for the info
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
To start off, I am a beginner MQL programmer. Now, here goes a beginner question.
I have a variable defined in my EA:
However, when the EA trades, it uses 1.0 lots, even though the 0.1 is set under variable above. Could anyone please be so kind to explain me how do I make sure that EA uses the lot size I set in the variable? Is there any special code I need to add to my expert?
Thanks in advance,
Diam0nd.