End orders but not active trade

Forums ProRealTime English forum ProOrder support End orders but not active trade

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

    Hello everyone, I’m very new to all of this so this is probably a basic question for you.

    I want my pending orders to stop at a certain time but my code also stops any active trades. So far I have this:

    DEFPARAM FLATBEFORE=073000

    DEFPARAM FLATAFTER=083000

     

    How do I just let the active trades continue without being stopped?

    #223927

    Pending orders only last one bar. So you don’t need to cancel them. Just stop placing them after the time of your choice. This is valid for intraday timeframes.

    If you are trading a daily timeframe you will need to resort to multiple timeframe, so that you can place pending orders in an intraday timeframe, stopping placing them when needed.

     

    #223937

    the pending orders do stop but its the active trade I’m concerned about. It gets stopped wherever it is at the DEFPARAM FLATAFTER time. I just want it to continue

    #223959

    Roberto is right, you just need to remove your flatafter and not to place WO.

    #223963

    I want my pending orders to stop at a certain time but my code also stops any active trades.

    Possibly you don’t realize that a “pending order” is a functional phenomenon which really is different than “a program code which must stop trading new orders”.
    I think you refer to the latter. In that case, you should try to make something like this :

    A Pending Order is of the form

     

    #224099

    Hmm still not working for me. Trades are coming in after 830 with that code still

    #224133

    Can you show the code of concern ?

    #224226

    I figured it out. I just had to add endtime = 083000 and then add endtime to my orders line

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