• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

ToDay(Time[0]) Rounded Off to 20M?

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

    ToDay(Time[0]) Rounded Off to 20M?

    Hi,

    In the market analyzer, my indicator of that includes ToDay(Time[0]) is rounded off to 20M which is not very informative. Is there a way to display the whole integer like 20130101?

    Thanks.

    #2
    Hi Usuallywin,

    Thank you for posting.

    This is because the ToTime() returns an int of the date time structure. You can use the Time[0].ToString to return the full date time structure.

    Let me know if I can be of further assistance.
    Cal H.NinjaTrader Customer Service

    Comment


      #3
      Thanks for your reply. However, I believe that a string cannot be .set() as an indicator, therefore cannot be displayed in the market analyzer. Is that correct?

      Is there a way to display the full integer without rounding off?

      Comment


        #4
        Hi Usuallywin,

        You will need to override the price marker format to display a string -
        Code:
        public override string FormatPriceMarker(double price)
        		{
        			return DateTime.Now.ToString("MM/dd/yyyy H:mm:ss");
        		}
        http://www.ninjatrader.com/support/h...ricemarker.htm

        Let me know if I can be of further assistance.
        Cal H.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by epitoma, Today, 05:21 PM
        1 response
        12 views
        0 likes
        Last Post NinjaTrader_ShawnB  
        Started by BatBart, Today, 01:24 PM
        1 response
        22 views
        0 likes
        Last Post NinjaTrader_Melissa  
        Started by ezrakoper, Today, 03:05 PM
        1 response
        7 views
        0 likes
        Last Post NinjaTrader_ChelseaB  
        Started by asmmbillah, Today, 02:23 PM
        1 response
        17 views
        0 likes
        Last Post NinjaTrader_Jesse  
        Started by steveg, Today, 02:44 PM
        1 response
        9 views
        0 likes
        Last Post NinjaTrader_Heath  
        Working...
        X