Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Drawing Object Permanent

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

    Drawing Object Permanent

    If I manual draw a rectangle or text on the chart it remains on the chart until I delete it. So if I reload historic data or open or close ninja the drawing objects stay. But when I draw inside my indicator it does not remain.

    ls there a setting to tell this drawing object to stay permanent until I deleted it.

    Specifically inside the indicator, when there is a news event I want to draw a drawing object and label it as news event. That I can do. But I want it to remain even if I close Ninja and reopen it, until I delete it.

    The problem is when you reopen ninja that news story is gone and the one drawn is gone.

    #2
    Hello Rwbil,

    Thank you for your note.

    There is no way to have the draw object not be deleted when restarting NinjaTrader or reloading the Indicator.

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

    Comment


      #3
      Originally posted by rwbil View Post
      If I manual draw a rectangle or text on the chart it remains on the chart until I delete it. So if I reload historic data or open or close ninja the drawing objects stay. But when I draw inside my indicator it does not remain.

      ls there a setting to tell this drawing object to stay permanent until I deleted it.

      Specifically inside the indicator, when there is a news event I want to draw a drawing object and label it as news event. That I can do. But I want it to remain even if I close Ninja and reopen it, until I delete it.

      The problem is when you reopen ninja that news story is gone and the one drawn is gone.
      You can write the time code of the drawing object to a file or save it to an array or list, then restore the object when NT restarts.

      Please view this post: http://www.ninjatrader.com/support/f...ad.php?t=70899
      (post #5)

      So write what? Write the time code of the object. Every DateTime object has a Ticks value, which I call the time code:
      DateTime t = drawingObject.Time; // this is just a pseudo code
      long timeCode = t.Ticks;
      Cheers,
      Pi
      Last edited by ninZa; 01-03-2015, 08:20 PM.
      ninZa
      NinjaTrader Ecosystem Vendor - ninZa.co

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by wzgy0920, 04-20-2024, 06:09 PM
      2 responses
      27 views
      0 likes
      Last Post wzgy0920  
      Started by wzgy0920, 02-22-2024, 01:11 AM
      5 responses
      32 views
      0 likes
      Last Post wzgy0920  
      Started by wzgy0920, 04-23-2024, 09:53 PM
      2 responses
      49 views
      0 likes
      Last Post wzgy0920  
      Started by Kensonprib, 04-28-2021, 10:11 AM
      5 responses
      193 views
      0 likes
      Last Post Hasadafa  
      Started by GussJ, 03-04-2020, 03:11 PM
      11 responses
      3,235 views
      0 likes
      Last Post xiinteractive  
      Working...
      X