New position for a strategy.

Forums ProRealTime English forum ProOrder support New position for a strategy.

Viewing 7 posts - 1 through 7 (of 7 total)
  • #142241

    Just one more question:

    In the strategy there can be a maximum of 2 positions.
    After a first position, buy another position if the same conditions as the first position are met.
    Or, buy another position, if the price falls 1% from the first position.

    #142298

    Not tested:

     

    #142299

    Thanks Grahal!

    But there is a problem … I can’t get it to work the way I want.

    In the strategy there can be a maximum of 2 positions.
    After a first position, buy another position if the price falls 1% from the first position.

    The strategy with your code buys the two positions when the same conditions are met.
    What I want is that I only buy the first position with conditions, and the second position if the price falls 1% from the first position.


    The first photo is what I have so far.
    The second photo shows that it always buys the second position when the conditions of the first position are met, since it always buys the second position a few pips after the first position.

     

    #142305

    That’s what you asked

    After a first position, buy another position if the same conditions as the first position are met.
    Or, buy another position, if the price falls 1% from the first position
    .

    I am not GraHal.

    If you don’t want to buy the second position with the same conditions as the first one, change line 9:

     

    #142310

    Jjhajjjaaa!!!

     

    Sorry Roberto!

    #142327

    No function.

    #142332

    Post your code if you want help about it, instead of general examples.

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

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