My Ea does not open lot. It stops at 0.1 lot. Everyone understands why
Hey bridge.... Seems like your ea has a minimum lot dimensions coded in.... That's common....
Hunt the ea for 0.1, ought to be related to lots.... You'll probably need to reduce the minimal value....
When the ea is posted somewhere , let us know and we could tell for certain, otherwise it's simply an edued guess...h
Inserted Code if(lotlt;0.1) lot = 0.1; //-- if(lotlt;0.01) lot = 0.01;
Can't tell you. But my FXCM Micro Demo lets me exchange micro lots and then I can not do smaller than .1 in my EA. I confirmed that this was deliberate by checking the Minlot setting. Didn't check every pair, but it was accurate for EURUSD and GBPUSD.Originally Posted by ;
double lots = MarketInfo(Symbol(), MODE_MINLOT);
Ive notice this to and Ive alter it for
if(lotlt;0.01) lot = 0.01;
However there is no lot size in beetween... The EA opens 0.01 lot or it switch to 0.1, cant get 0.02 or 0.03... I would also prefer to have 0.12 0.14 or 0.36. Do you know how to do this.
Here's the part of the code associated with the lot size
Calculate best lot size |
// ------------------------------------------------------------------
dual LotsOptimized()
{
double lot=Lots;
int orders=HistoryTotal(); // history orders total
int losses=0; // amount of losses orders without a fracture
//-- select lot size
lot=NormalizeDouble(AccountFreeMargin()*MaximumRis k/1000.0,1);
//-- yield lot size
if(lotlt;0.01) lot=0.01;
yield(lot);
Originally Posted by ;
Try , and I say try ,to alter :
lot=NormalizeDouble(AccountFreeMarg in()*MaximumRisk/1000.0,1);
into:
lot=NormalizeDouble(AccountFreeMarg in()*MaximumRisk/1000.0,2);
It should work , because number of digits after decimal point have changed from 1 (xx,y) to two (xx,yy).
Hope this help and sorry for my english
yOU KNOW WHAT!!! Ilt;t try it and it functioned Thanks Doctor I feel much better now!!!Originally Posted by ;