Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

SessionBegin and SessionEnd and ExitOnClose

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    SessionBegin and SessionEnd and ExitOnClose

    Hello, I have a question using SessionBegin and SessionEnd.

    In a previous thread


    you state that ExitOnClose is tied to the SessionEnd variable.

    Now from within debugging I see that when in the strategy SessionBeginn is 0.00 and SessionEnd is 0.00 these times are stored internally as different times.
    SessionBegin is stored as 01/01/0001 0:00 and
    SessionEnd is stored as 01/12/2099 0:00 ( this seems to be licence expiry)


    Now my question:

    How does ExitOnClose behave?

    Will ExitOnClose use only the hour:minute section of the SessionEnd or will also the date section of SessionEnd be used?

    eg. Setting ExitOnClose to 17:30 1/12/2099 , will this trigger an Exit Order at the End of the Session?

    Best regards
    andreas

    #2
    I answer by myself:

    ExitOnClose will trigger only at SessionEnd Time (e.g in 2099) if not changed from within my code).

    From the Strategy Property sheet if changing SessionEnd time the DateTime will be the current Date!

    Comment


      #3
      Actually my whishlist is the following:

      Since the strategy knows the instrument it is running on, you also know on which exchange this instrument is, and therefore NT should also know the Session Times for that Instrument on the exchange.

      Why do I have to put this by hand?

      There NT should automatically set SessionBegin and SessionEnd.

      Al ExitClose related staff should be relative to these

      regards

      Comment


        #4
        zweistein, sorry for my late reply here - NinjaTrader 7 will offer a session manager that simplifies this process.
        BertrandNinjaTrader Customer Service

        Comment


          #5
          I am not interested in NT7 now, as I trade real money and I cannot risk using a beta software environment for trading.

          Best regards

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by alifarahani, Today, 09:40 AM
          6 responses
          32 views
          0 likes
          Last Post alifarahani  
          Started by Waxavi, Today, 02:10 AM
          1 response
          17 views
          0 likes
          Last Post NinjaTrader_LuisH  
          Started by Kaledus, Today, 01:29 PM
          5 responses
          14 views
          0 likes
          Last Post NinjaTrader_Jesse  
          Started by Waxavi, Today, 02:00 AM
          1 response
          12 views
          0 likes
          Last Post NinjaTrader_LuisH  
          Started by gentlebenthebear, Today, 01:30 AM
          3 responses
          17 views
          0 likes
          Last Post NinjaTrader_Jesse  
          Working...
          X