Partial close and breakeven

Forums ProRealTime English forum ProOrder support Partial close and breakeven

Viewing 8 posts - 1 through 8 (of 8 total)
  • #193263

    Hello!

    I’m trying to combine partial close with a breakeven, but am unable to get it to work. The problem seems to be that the breakeven doesn’t “reset” between positions. Any ideas on how to do this?

    #193268

    If you want to reset variables to their initial states, please do it preferably at the top of the code.

    So this:

    should be located before this:

     

    #193269

    Understood! Doesn’t seem to make a difference in this case though. Did you happen to try it out?

    #193284

    If you try with two separate snippets? (Dax 15m)

     

    #193304

    I think you are right, this version works much better, I set a wide stoploss at orders launch, then the breakeven is set upon your conditions (I fixed a partial exit size calculation problem too).

     

    1 user thanked author for this post.
    #193383

    Thanks! That works well.

    I now have another issue. When I use set stop ploss 200, or set stop %loss 1, it works. But when I use my custom stop loss, it doesn’t. I don’t understand why. Any ideas?

    #193394

    Because once you set SET STOP BREAKEVEN, it will last forever and for any subsequent orders, until you set the stoploss to 0 or any other value with a SET STOP instruction (SET STOP LOSS 0 for instance at order launch).

    1 user thanked author for this post.
    #193403

    Much appreciated!

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

Create your free account now and post your request to benefit from the help of the community
Register or Login