Reply

Breakeven and error 130

6 replies

Mohamdyoon

Subscriber, bbp_participant, community, 5 replies.

Visit profile

6 years ago #116710

Hello ,
I have a problem with Breakeven level
I want to set Breakeven at 10 pips when the price reach that level
so my parameters will be : move breakeven to stop loss >>10 pips ,,,,, breakeven Add Pips >> 10 pips
that worked in the first time and it was really good but after that and without any reasons it gives me order Modify error 130 which goes away if I make ( move breakeven to stop loss ) >> 15 for example (ie: I make it far from breakeven Add Pips)
it has nothing to do with the strategy or any other options as I removed every thing and just keeps this in the file and the problem persists 

0

tomas262

Administrator, sq-ultimate, 2 replies.

Visit profile

6 years ago #142740

Hello,

 

do you want to move SL into breakeven I mean open P/L equals to 0?

 

If you set Move to BE to 10 pips and Add pips to 10 you basically violate “minimum stop distance” – you cannot move to 0 pips from last price

0

Mohamdyoon

Subscriber, bbp_participant, community, 5 replies.

Visit profile

6 years ago #142742

Yeah of course I violated stop levels here , How Can I miss that ! 
Thank you

0

Mohamdyoon

Subscriber, bbp_participant, community, 5 replies.

Visit profile

6 years ago #142743

but why in very rare cases in gives me error 1 even when all the conditions is good and I’m far away from stop level >> the error means that there’s no result ( ie : it sends the same SL or TP ) 

0

tomas262

Administrator, sq-ultimate, 2 replies.

Visit profile

6 years ago #142753

Hello,

 

error 1 usually means that the OrderModify function attempts to replace the values already set before. One or more values must be changed then modification attempt can be repeated.

 

If you attach your project or send to [email protected] I can check it for you

0

Mohamdyoon

Subscriber, bbp_participant, community, 5 replies.

Visit profile

6 years ago #142787

thanks I have figured it out but regarding the first problem can you please point to the part of the code which actually move the stop loss 2 BE so I can manually edit it so it will be beyond the stops level , I have a little knowledge let me do that I thinks but I just can’t find that part , I can find only the part of Verbose which telling me that we are going to move SL 2 BE  ( that part which contains Trailing stop then Breakeven for each magic number )

0

tomas262

Administrator, sq-ultimate, 2 replies.

Visit profile

6 years ago #142850

Hello,

 

the move to breakeven as you described it can be setup like this. See file attached

0

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