Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Global Drawing Tools aren't deleted until indicator's chart is focused

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

    Global Drawing Tools aren't deleted until indicator's chart is focused

    I've found a bug in the removal of Global Drawing Tools.
    If you use RemoveDrawObject(globalDrawingToolId) to remove a Global Drawing Tool, without including an @ before the id, it won't be deleted until the chart of the indicator that created it is focused.

    I've attached a sample indicator that displays this behavior. For every new candle after it reaches State.Transition, it removes the last line, and draws a new global line with a random id, connecting the highs of the 10th last candle with the last candle.

    To reproduce the bug, insert the indicator into a chart, switch to another tab of the same Instrument, and wait for a candle to close. The old line won't be removed until you open the tab that the indicator is inserted.

    Removing the Draw Object using an @ sign before the id fixes this, but this seems like unexpected behavior nonetheless.
    Attached Files

    #2
    Hello Matheusfx,

    Thanks for your post.

    I've tested the indicator and I don't see the issue.

    Here is a short video of what I see here: https://Paul-ninjaTrader.tinytake.co...OF8xNTUxMjQxNQ

    What version of Ninjatrader8 are you testing this on? (Look under help>About).

    Comment


      #3
      Sorry, I've sent the file with the workaround included by mistake. I've edited the file in the main post with the problematic code!

      For reference, I'm using the latest version (8.0.23.1 64-bit)
      Last edited by Matheusfx; 12-14-2020, 01:56 PM.

      Comment


        #4
        Hello Matheusfx,

        Thanks for your reply.

        Regrettably, the file link now returns: "Invalid File Specified"

        Also, please confirm that you are using and have tested with Ninjatrader 8.0.23.1

        Comment


          #5
          I've reuploaded the file, the download should be working now. Also, I've rechecked my NT8 version and I am indeed in the latest version.

          Comment


            #6
            Hello Matheusfx,

            Thanks for your effort to update.

            I now see the unremoved lines.

            We will review and update this thread when we have further information.

            Thanks in advance for your patience.

            Comment


              #7
              Any updates on this issue?

              Comment


                #8
                Hello Matheusfx,

                Thanks for your reply.

                The QA has performed their review and it is now in the developments groups que to fix.

                Typically a fix will be made available on the next release of NinjaTrader8.

                We cannot advise when the next release of NinjaTrader8 will occur.

                Comment

                Latest Posts

                Collapse

                Topics Statistics Last Post
                Started by Geovanny Suaza, 02-11-2026, 06:32 PM
                0 responses
                577 views
                0 likes
                Last Post Geovanny Suaza  
                Started by Geovanny Suaza, 02-11-2026, 05:51 PM
                0 responses
                334 views
                1 like
                Last Post Geovanny Suaza  
                Started by Mindset, 02-09-2026, 11:44 AM
                0 responses
                101 views
                0 likes
                Last Post Mindset
                by Mindset
                 
                Started by Geovanny Suaza, 02-02-2026, 12:30 PM
                0 responses
                553 views
                1 like
                Last Post Geovanny Suaza  
                Started by RFrosty, 01-28-2026, 06:49 PM
                0 responses
                551 views
                1 like
                Last Post RFrosty
                by RFrosty
                 
                Working...
                X