Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

ToTime (Time [0])

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

    ToTime (Time [0])

    hello,

    I have a statement like this does not work:

    if (ToTime (openHour 1, openMinute, 0) == ToTime (Time [0]))

    I tried this too, the same pb:

    if ((ToTime (Time [0]) == ToTime (startTime.AddHours (1)))

    how can I do?

    Note: this works in 6.5

    #2
    Please be more specific as to why you feel it doesn't work and what you are experiencing instead. Thank you.
    Josh P.NinjaTrader Customer Service

    Comment


      #3
      I have this on 6.5:

      if (ToTime (startTime.AddHours (1). Hour, startTime.Minute, 0) == ToTime (Time [0]))
      {
      do something
      }

      to see if it works, I tested this

      if (ToTime (startTime.AddHours (1). Hour, startTime.Minute, 0) == ToTime (Time [0]))
      DraxTexteFixe

      and nothing appears, therefore, I supposue I can not fit in the loop.

      Comment


        #4
        Suggest you debug your code and print the components individually so you can evaluate it by hand.
        Josh P.NinjaTrader Customer Service

        Comment


          #5
          hello,

          I found the solution.
          The non-execution of this instruction was linked to the start time of the instrument.
          In choosing the Eurex Fixed (8h00-22h00), everything is back to normal.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by Hwop38, 05-04-2026, 07:02 PM
          0 responses
          168 views
          0 likes
          Last Post Hwop38
          by Hwop38
           
          Started by CaptainJack, 04-24-2026, 11:07 PM
          0 responses
          322 views
          0 likes
          Last Post CaptainJack  
          Started by Mindset, 04-21-2026, 06:46 AM
          0 responses
          246 views
          0 likes
          Last Post Mindset
          by Mindset
           
          Started by M4ndoo, 04-20-2026, 05:21 PM
          0 responses
          350 views
          0 likes
          Last Post M4ndoo
          by M4ndoo
           
          Started by M4ndoo, 04-19-2026, 05:54 PM
          0 responses
          179 views
          0 likes
          Last Post M4ndoo
          by M4ndoo
           
          Working...
          X