Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Display bar number somewhere

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

    Display bar number somewhere

    I'd like to have a way to display the bar number. This would really facilitate debugging my scripts. Either one of these would make me happy:
    • Beside or underneath the date in the Data Box
    • Beside the Time on the X-axis crosshair label
    If there's already a way to see the number of a particular bar while viewing a chart, I'd like to know.

    Right now I must insert the line Print(CurrentBar.ToString()+" "+Time[0].ToString()) in my indicator to get a list of bar numbers in the output window corresponding to each date/time. It would be nice not to have to do that.

    -A

    #2
    Hi anachronist,

    There is at least one script in the file sharing section that does this. Check the 6.5 and 7 indicators section and let me know if you're not able to find it.

    You can also custom program a solution here, by using CurrentBar in a DrawText() statement.

    Ryan M.NinjaTrader Customer Service

    Comment


      #3
      Thanks for the advice. The point is to be able to hover the mouse over a bar and see the number. DrawText() won't work for that purpose.

      I guess I could write a simple indicator that displays the bar number; then it would show up in the Data Box.

      -A

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by FrazMann, Today, 11:21 AM
      2 responses
      6 views
      0 likes
      Last Post NinjaTrader_ChristopherJ  
      Started by rjbtrade1, 11-30-2023, 04:38 PM
      2 responses
      80 views
      0 likes
      Last Post DavidHP
      by DavidHP
       
      Started by Spiderbird, Today, 12:15 PM
      1 response
      7 views
      0 likes
      Last Post NinjaTrader_ChristopherJ  
      Started by lorem, Yesterday, 09:18 AM
      5 responses
      18 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Started by cmtjoancolmenero, Yesterday, 03:58 PM
      12 responses
      42 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Working...
      X