Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

ToTime set

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

    ToTime set

    Hi ,

    I just try set a strategy and I have one problem. If anyone know how to resolve it ,I will be very glad!! I just have a easy condition (Open[0] > High[1] && High[0] < Low[1] and I cant set specific time for it. I need calculate for example just between 08: 00 am to 09: 00am .

    && ToTime(08, 00, 00) == ToTime(09, 00, 00).

    Thanks for any help!

    Jake

    #2
    Originally posted by Jakub View Post
    Hi ,

    I just try set a strategy and I have one problem. If anyone know how to resolve it ,I will be very glad!! I just have a easy condition (Open[0] > High[1] && High[0] < Low[1] and I cant set specific time for it. I need calculate for example just between 08: 00 am to 09: 00am .

    && ToTime(08, 00, 00) == ToTime(09, 00, 00).

    Thanks for any help!

    Jake
    I think it is more like

    if (ToTime(Time[0]) >= 80000 && ToTime(Time[0]) <= 90000)

    Comment


      #3
      Originally posted by Kevin_in_GA View Post
      I think it is more like

      if (ToTime(Time[0]) >= 80000 && ToTime(Time[0]) <= 90000)
      This is how I rolled. I guess I could eliminate the 2 extra ToTime calls by removing it for 80000 and 90000 like you have.

      if ( ToTime(Time[0]) >= ToTime( 8, 00, 00)
      && ToTime(Time[0]) <= ToTime( 9, 00, 00))
      {
      Print ( "ToTime(Time[0])=" + ToTime(Time[0]));


      }

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by CarlTrading, 03-31-2026, 09:41 PM
      1 response
      68 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Started by CarlTrading, 04-01-2026, 02:41 AM
      0 responses
      39 views
      0 likes
      Last Post CarlTrading  
      Started by CaptainJack, 03-31-2026, 11:44 PM
      0 responses
      63 views
      1 like
      Last Post CaptainJack  
      Started by CarlTrading, 03-30-2026, 11:51 AM
      0 responses
      62 views
      0 likes
      Last Post CarlTrading  
      Started by CarlTrading, 03-30-2026, 11:48 AM
      0 responses
      53 views
      0 likes
      Last Post CarlTrading  
      Working...
      X