Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

NinjaTrader and time Zone

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

    NinjaTrader and time Zone

    I need to understand something. How does NinjaTrader 8 uses different time Zone.

    If I develop an indicator and apply a trading hour session based on NY time.
    I also use DateTime.Now throughout my code.

    How does an Australian customer can use my indicator ?
    Does he have to create a new trading hour session based on Australian time zone or do I have to address that time zone problem within my code ?


    Thanks

    #2
    Hello,

    Thank you for the post.

    DateTime.Now specifically would refer to the clock of the PC being used. We generally suggest against using this as this would not relate to anything specifically in the platform. If you are using an indicator or strategy the DateTime.Now would not relate to any specific bar but may coincide with a ticks time potentially.

    As I am unsure what you are using DateTime.Now for currently, I couldn't really provide an alternative if there was something more acceptable for the use.

    Generally, in the platform, you would use the Time objects as these would relate to the chart data the user is seeing and would be formatted for the user.

    In NT8 the platform specifically uses NinjaTrader.Core.Globals.Now when it needs to use the PC time, this would likely be suggested if you have a similar use. This is not a documented item currently.

    If you can provide more context on how you are using DateTime.Now, I could likely provide a more direct answer.

    I look forward to being of further assistance.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by CarlTrading, 03-31-2026, 09:41 PM
    1 response
    156 views
    1 like
    Last Post NinjaTrader_ChelseaB  
    Started by CarlTrading, 04-01-2026, 02:41 AM
    0 responses
    90 views
    1 like
    Last Post CarlTrading  
    Started by CaptainJack, 03-31-2026, 11:44 PM
    0 responses
    138 views
    2 likes
    Last Post CaptainJack  
    Started by CarlTrading, 03-30-2026, 11:51 AM
    0 responses
    130 views
    1 like
    Last Post CarlTrading  
    Started by CarlTrading, 03-30-2026, 11:48 AM
    0 responses
    107 views
    0 likes
    Last Post CarlTrading  
    Working...
    X