Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Print Statement that allows for seconds

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

    Print Statement that allows for seconds

    Hi,

    I would like some assistance with using the Print() method. I am able to print the date and time but would like to include seconds also, how can this be done?

    Regards,
    suprsnipes

    #2
    String.Format

    Code:
     + String.Format( "{0:MM/dd HH:mm:ss}",Times[0][0]) +
    Originally posted by suprsnipes View Post
    Hi,

    I would like some assistance with using the Print() method. I am able to print the date and time but would like to include seconds also, how can this be done?

    Regards,
    suprsnipes

    Comment


      #3
      Can I please ask an additional question?

      If a multi instrument indicator condition is true and the series loaded on the main and secondary instrument is 1 minute will the timestamps print second data?

      As I have seen that even using the code suggested in the previous post;

      Code:
        + String.Format( "{0:MM/dd HH:mm:ss}",Times[0][0]) +
      However when I change the input series on both of the instruments to 1 second the timestamps are now showing seconds data? Is this correct?

      Thanks in advance,
      suprsnipes

      Comment


        #4
        I think what you are asking would be true, but without performing a test, I can not be certain.

        But in general, if there are seconds available, they will print with the format command. Else 00 would imply you are looking at xx minute bar.. ?









        Originally posted by suprsnipes View Post
        Can I please ask an additional question?

        If a multi instrument indicator condition is true and the series loaded on the main and secondary instrument is 1 minute will the timestamps print second data?

        As I have seen that even using the code suggested in the previous post;

        Code:
          + String.Format( "{0:MM/dd HH:mm:ss}",Times[0][0]) +
        However when I change the input series on both of the instruments to 1 second the timestamps are now showing seconds data? Is this correct?

        Thanks in advance,
        suprsnipes

        Comment


          #5
          Ok, thanks. I will test it out.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by Geovanny Suaza, 02-11-2026, 06:32 PM
          0 responses
          581 views
          0 likes
          Last Post Geovanny Suaza  
          Started by Geovanny Suaza, 02-11-2026, 05:51 PM
          0 responses
          338 views
          1 like
          Last Post Geovanny Suaza  
          Started by Mindset, 02-09-2026, 11:44 AM
          0 responses
          103 views
          0 likes
          Last Post Mindset
          by Mindset
           
          Started by Geovanny Suaza, 02-02-2026, 12:30 PM
          0 responses
          554 views
          1 like
          Last Post Geovanny Suaza  
          Started by RFrosty, 01-28-2026, 06:49 PM
          0 responses
          552 views
          1 like
          Last Post RFrosty
          by RFrosty
           
          Working...
          X