Reply

Cannot figure out 131 invalid trade volume on DAX and US30

8 replies

jmtc1230

Customer, bbp_participant, community, 19 replies.

Visit profile

6 years ago #116714

Hey all,
 
Can anybody advise me in this?  I am having an issue with using the proper lot sizes for DAX and US30.  Broker is IC Market.  
 
Settings in the EA are:
Lots = .1
Lots Decimals = 2
 

 

Specifications from broker are: 

Digits = 2

Contract size = 1

Minimal volume = 1.00

Max volume = 250

Volume step = 1.00

 

 

Code in the EA is:

extern string __s6 = “—–  Money Management Parameters  ———–“;
extern bool UseMoneyManagement = false;
extern double Lots = 0.1;
extern int LotsDecimals = 2;
extern double RiskInPercent = 2.0;
extern double MaximumLots = 0.5;
extern bool UseFixedMoney = false;
extern double RiskInMoney = 100.0;
 

 

AND HERE IS THE RESULT FROM TRADING:
2017.04.24 14:59:59.948 4008 Strategy 13.31 US30,H1: 2017.04.24 22:00:00 Error opening order: 131 : invalid trade volume

 

 

My goal is to have the EA request lots of 1.0.  I am not sure how to accomplish this.

 

Thank you for your input. I appreciate it.

0

tomas262

Administrator, sq-ultimate, 2 replies.

Visit profile

6 years ago #142738

Hello,

 

try to change extern int LotsDecimals = 2; to extern int LotsDecimals = 1;

It could solve the issue with the invalid volume error 131

 

Let me know

0

jmtc1230

Customer, bbp_participant, community, 19 replies.

Visit profile

6 years ago #142744

Tomas,

 

Thanks for the tip but there is no improvement.  Can you take another look into this please?  Thanks for the input.

 

 

Josh

0

jmtc1230

Customer, bbp_participant, community, 19 replies.

Visit profile

6 years ago #142759

Tomas,

 

Here are the strategies.

 

4001 is for the DOW30.

5001 is for the DAX.

 

 

 

Josh

 

 

 

 

 

0

jenial

Customer, bbp_participant, community, sq-ultimate, 7 replies.

Visit profile

6 years ago #142761

I have ths same issue with Lmfx broker, haven’t figured out yet how to solve this issue.

0

tomas262

Administrator, sq-ultimate, 2 replies.

Visit profile

6 years ago #142770

Hello,

 

the Dax strategy works for me. See screenshot. With the error message there should be also message about lot size applied. What lot size it tried to trade causing error? Can you check that? I suspect it has something to do with settings at your brokerage

File: dax.jpgdax.jpg

0

jmtc1230

Customer, bbp_participant, community, 19 replies.

Visit profile

6 years ago #142774

Tomas,

 

I cannot get any lot sizes/lotsdecimals to work.  What did work for you?

 

 

Josh

0

tomas262

Administrator, sq-ultimate, 2 replies.

Visit profile

6 years ago #142776

Hello,

 

your broker’s Minimal volume = 1.00 but you use 0.5 lots in the EA. That’s the problem. Set extern double MaximumLots = 1.0; or higher and it will work with MM = false

0

jmtc1230

Customer, bbp_participant, community, 19 replies.

Visit profile

6 years ago #142781

Tomas,

 

Your last comment nailed it.  Thank you so much for you help.  The lots must be 1.0 and the max lots must be higher than that.

 

 

Josh

0

Viewing 8 replies - 1 through 8 (of 8 total)