• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

How to remove all drawing objects from a chart from code ?

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

    How to remove all drawing objects from a chart from code ?

    How can i remove all drawing objects on the chart from code ?
    Basicly i would like to do drawing tool-> remove all drawing objects to remove all objects, but without the confirmation question popping up whether i really want this or not.

    #2
    Hello Erwin BEckers,
    Thanks for your post.

    You can remove all drawing objects from your chart programmatically by using RemoveDrawObjects()
    Please see the following link for more information: https://ninjatrader.com/support/help...rawobjects.htm

    Additionally, we have a reference sample in the help guide that demonstrates how to remove a drawing object. Please see the following link for that: https://ninjatrader.com/support/help...s_from_the.htm
    JoshNinjaTrader Customer Service

    Comment


      #3
      Originally posted by Erwin Beckers View Post
      How can i remove all drawing objects on the chart from code ?
      Basicly i would like to do drawing tool-> remove all drawing objects to remove all objects, but without the confirmation question popping up whether i really want this or not.
      Erwin,

      You can download and Install my A MahToolBar indicator and use any drawing tool or remove all drawing objects with only one click. The ToolBar will install in the main chart toolbar to save chart space and you can select all or as many buttons for your favorite drawing tools as you wish. The indicator is located in User Apps section, Here:

      https://ninjatraderecosystem.com/use...-mahtoolbar-2/

      Cheers!

      Comment


        #4
        Thx Josh..
        but that will only remove the draw objects from that specific indicator or drawing tool.. I would like to remove ALL draw objects.. without popups asking for confirmation.

        Thx Aligator,
        yeah i saw your toolbar.. I'm actually building my own (floating) toolbar (see below) which has lots of extra tools llike Elliott wave, gann square, wolf range, auto range, custom risk/reward tools etc etc.
        using SendKeys kind of works.. But you get a popup asking are you sure you want to delete... all the time which i don't like.. and it requires users to setup a hotkey mapping..
        imo there should just be some simple api call available allowing us to clear the chart of any drawing objects..

        Click image for larger version

Name:	toolbar.jpg
Views:	1
Size:	375.5 KB
ID:	1041527

        Comment


          #5
          Erwin Beckers,

          It is not currently possible to do this.


          I am seeing two separate feature requests that I will add a vote to on your behalf .

          The first, SFT-2062, is to remove the confirmation window when removing drawing objects.

          The second, SFT-356, is to add NinjaScript functionality to remove manually drawn objects.


          When a feature request is implemented, you'll find it in the release notes:

          http://ninjatrader.com/support/helpG...ease_notes.htm



          Please let me know if you have any further questions.

          JoshNinjaTrader Customer Service

          Comment


            #6
            Erwin, I expect you will find it useful to examine how this toggle indicator works: https://ninjatraderecosystem.com/use...ers-and-wicks/

            BTW, thank you for creating and posting the Measured Move tool. I use it every day.

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by ralett, Today, 11:44 AM
            1 response
            12 views
            0 likes
            Last Post NinjaTrader_Spencer  
            Started by DMDINAZ, Today, 11:03 AM
            1 response
            8 views
            0 likes
            Last Post NinjaTrader_ChelseaB  
            Started by sukhob, Today, 10:14 AM
            4 responses
            10 views
            0 likes
            Last Post sukhob
            by sukhob
             
            Started by beaacontreras, Today, 09:27 AM
            1 response
            20 views
            0 likes
            Last Post NinjaTrader_PatrickG  
            Started by fxSol, 03-17-2019, 04:17 AM
            5 responses
            28 views
            0 likes
            Last Post NinjaTrader_ChristopherS  
            Working...
            X