Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

DateTime that is forever?

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

    DateTime that is forever?

    I'm trying to draw a rectangle that starts from a specific time but goes on forever. Feel like it should be easy but drawing a brain fart on this.

    I currently have this and it starts at the time I want it to but the end time currently I have set to end of day but want it to be where it goes on forever but not finding a way to do that.

    ```Draw.Rectangle(this, "startTime" + CurrentBar,Time[0], Lows[1][0] - TickSize,new DateTime(Time[0].Year, Time[0].Month, Time[0].Day, 16,15,0), Highs[1][0], Brushes.Transparent);

    Any ideas on this? I'm sure its really easy or a simple tweak to do this.

    #2
    vegas3416 Have you tried setting the endTime to DateTime.MaxValue or a DateTime way out in the future??

    Thanks.
    Multi-Dimensional Managed Trading
    jeronymite
    NinjaTrader Ecosystem Vendor - Mizpah Software

    Comment


      #3
      Hello vegas3416,

      You appear to want something like a ray where one end is extended but with a rectangle. The Rectangle drawing tool isn't really meant for that. You could re-draw on each new bar to the current bar (with the end date as Time[0]).

      You could look into finding or creating a custom coded addon.

      Below is a link to a thread that discusses.
      I've seen some questions about this before, but I'm just reviving this feature request. I already know of the highlight region tool which is a great start. It would just be nice to have the region have a starting point rather than just highlight the whole chart. (Basically, a rectangle tool with no right side limit.) Post in
      Chelsea B.NinjaTrader Customer Service

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by CarlTrading, 03-31-2026, 09:41 PM
      1 response
      47 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Started by CarlTrading, 04-01-2026, 02:41 AM
      0 responses
      23 views
      0 likes
      Last Post CarlTrading  
      Started by CaptainJack, 03-31-2026, 11:44 PM
      0 responses
      33 views
      1 like
      Last Post CaptainJack  
      Started by CarlTrading, 03-30-2026, 11:51 AM
      0 responses
      51 views
      0 likes
      Last Post CarlTrading  
      Started by CarlTrading, 03-30-2026, 11:48 AM
      0 responses
      42 views
      0 likes
      Last Post CarlTrading  
      Working...
      X