Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

StartTime/EndTime format?

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

    #16
    Hello,

    You want to use the right tool for the right job. In this case DateTime is the best format for the job. ToTime has limitations that make it not able to use here and is a basic format in general that I suggest you graduate into using DateTime if possible as they have features(Like the one I just showed you) that make it the superior format for Date and Time manipulation.


    -Brett

    Comment


      #17
      No need to use a sledge hammer when a finishing hammer is the proper tool for the job. Graduating to DateTime would be a good thing when necessary, but it seems to me that all you did was make the Year, Month, and Date basically useless in this context, with only the hhmmss remaining. So then why use it in THIS application. NinjaTrader has obviouly designed Drawing Object syntax to be flexible for different programming needs. The DateTime "one size fits all" approach seems to be at odds with NinjaTrader's own flexibility standard.

      Thanks again for all your input
      Last edited by kenb2004; 07-17-2012, 08:24 AM.

      Comment


        #18
        No problem.

        Comment


          #19
          Originally posted by kenb2004 View Post
          No need to use a sledge hammer when a finishing hammer is the proper tool for the job. Graduating to DateTime would be a good thing when necessary, but it seems to me that all you did was make the Year, Month, and Date basically useless in this context, with only the hhmmss remaining. So then why use it in THIS application. NinjaTrader has obviouly designed Drawing Object syntax to be flexible for different programming needs. The DateTime "one size fits all" approach seems to be at odds with NinjaTrader's own flexibility standard.

          Thanks again for all your input
          Actually for what you want to do, you are going to have to access the DataTime() structure at some point as it is the only way you are going to get the value to differentiate different days: ToTime() is limited to returning an int, derived from the time component only.

          The point is then moot. If you are going to have to use the more powerful construct anyway, then just use it for everything in this particular instance.

          Comment


            #20
            koganam

            As always thanks for your expertise.

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by MikeTR, Today, 03:55 PM
            0 responses
            2 views
            0 likes
            Last Post MikeTR
            by MikeTR
             
            Started by sclay115, Today, 02:14 PM
            0 responses
            4 views
            0 likes
            Last Post sclay115  
            Started by helmutmedina, Today, 01:57 PM
            0 responses
            6 views
            0 likes
            Last Post helmutmedina  
            Started by renosdim01, 02-13-2025, 05:46 AM
            2 responses
            18 views
            0 likes
            Last Post renosdim01  
            Started by zagier, 01-15-2025, 05:10 AM
            13 responses
            70 views
            1 like
            Last Post zagier
            by zagier
             
            Working...
            X