Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

replay showing incorrect bar time

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

    replay showing incorrect bar time

    i am running a replay and when i put the print out put for following
    Bars.GetTime(0)

    it shows 2016-01-17 5:20:00 PM which is the last bar bar in the chart and not the time of the bar in play. how do i get the correct time of the bar in play

    #2
    Hello junkone,

    Thanks for your post.

    Please see the helpguide on GetBar: http://ninjatrader.com/support/helpG...us/?getbar.htm The definition shows, "Returns the bar index of the 1st bar from oldest to newest that matches the time stamp based on the DateTime parameter passed in. If the time stamp passed in is older than the 1st bar, a bar index of 0 is returned. If the time stamp is newer than the last bar, the last bar index is returned."

    Please use something like:

    Print ("End Time of Bar :"+Time[0]);

    Time[]: http://ninjatrader.com/support/helpG...eries_time.htm

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by kinfxhk, 07-13-2026, 10:18 AM
    0 responses
    34 views
    0 likes
    Last Post kinfxhk
    by kinfxhk
     
    Started by kinfxhk, 07-13-2026, 09:50 AM
    0 responses
    29 views
    0 likes
    Last Post kinfxhk
    by kinfxhk
     
    Started by kinfxhk, 07-13-2026, 07:21 AM
    0 responses
    36 views
    0 likes
    Last Post kinfxhk
    by kinfxhk
     
    Started by kinfxhk, 07-11-2026, 02:11 AM
    0 responses
    33 views
    0 likes
    Last Post kinfxhk
    by kinfxhk
     
    Started by SalmaTrader, 07-07-2026, 10:26 PM
    0 responses
    143 views
    0 likes
    Last Post SalmaTrader  
    Working...
    X