Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

DrawObjects w/Version 8.0.26.1 64-bit

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

    DrawObjects w/Version 8.0.26.1 64-bit

    Hello, In NT version 8.0.25.0 and 8.0.26.0 there is a problem with global drawings that do not get redraw after closing a chart and reopening it. This problem was not present in version 8.0.24.3. Please watch this short video to better understand the problem and how to reproduce it. https://youtu.be/_ulqiDyMlTg But


    Although I never received a follow-up response to my question linked above:
    After updating to version 8.0.26.1, I can no longer duplicate the issue described.


    1.) Should I just "assume" that this was something addressed and fixed?

    2.) Is there a reason that 26.1 was never added to the forum announcements?

    -------------------------------------------------------------------------------------------------------

    3.) Also, I'm still experiencing some irregularities with DrawObjects in 26.1
    (It's a bit too difficult to explain in text - Please see video link below




    Please Advise???


    -=Edge=-
    NinjaTrader Ecosystem Vendor - High Tech Trading Analysis

    #2
    Hello -=Edge=-,

    Thank you for your post.

    My understanding is that that particular issue is still with our QA team, however, some fixes to RemoveDrawObject() may have actually resolved that as well, we'll know for sure when we hear back from our QA team on that one.

    As far as the new issue goes, I will make a test script and see if I can reproduce on my end. I'll let you know my findings once I've had a chance to create a script and test on my end.

    Thanks in advance; I look forward to assisting you further.
    Kate W.NinjaTrader Customer Service

    Comment


      #3
      Originally posted by NinjaTrader_Kate View Post
      we'll know for sure when we hear back from our QA team on that one.
      Thanks.. I'll try to continue patiently waiting..

      Originally posted by NinjaTrader_Kate View Post
      As far as the new issue goes, I will make a test script and see if I can reproduce on my end. I'll let you know my findings once I've had a chance to create a script and test on my end.
      To Hopefully help save time on this one, I've attached modified default RegionHighlight used in demonstration..

      1.) Open NT to Blank WorkSpace
      2.) Open OutPut Window
      3.) Open NS Editor
      4.) Open Windows File Explorer
      5.) BackUp First, then Delete @RegionHighlight.cs from Drawing Tools Folder
      6.) After Compile, Copy attached RegionHighlight.cs to DrawingTools folder
      7.) After Compile, Open Any Chart and Test

      Please Advise???


      Attached Files
      -=Edge=-
      NinjaTrader Ecosystem Vendor - High Tech Trading Analysis

      Comment


        #4
        Originally posted by NinjaTrader_Kate View Post
        Thanks in advance; I look forward to assisting you further.
        Another totally separate issue I'm now also experiencing..
        Attached is sample DrawingTool script.. "MyCustomDrawingTool"

        1.) Open NT to Blank WorkSpace
        1.) Open OutPut Window
        2.) Open NS Editor
        3.) Copy MyCustomDrawingTool.cs to DrawingTools folder
        4.) After Compile, Open Any Chart
        5.) Now Right Click anywhere on Chart

        Is there a reason multiple OnStateChanges Print on every Right Click?

        Please Advise???

        Attached Files
        -=Edge=-
        NinjaTrader Ecosystem Vendor - High Tech Trading Analysis

        Comment


          #5
          Hello -=Edge=-,

          Thank you for your post.

          I'm seeing that State.Configure isn't being hit again when you reload NinjaScript with the RegionHighlight.cs. This appears to be expected. We've got 2 instances of the drawing object we're actually looking at when we reload NinjaScript. The Hash value will let us keep track of which instance we're looking at, the original or the new instance created by reloading:

          Current State: SetDefaults Hash: 19511054
          StateDefault : 19511054 NinjaTrader.NinjaScript.DrawingTools.RegionHighlig htY 6/23/2022 1:59:47 PM False
          Current State: SetDefaults Hash: 19511054
          StateDefault : 19511054 NinjaTrader.NinjaScript.DrawingTools.RegionHighlig htY 6/23/2022 1:59:47 PM False
          Current State: Configure Hash: 19511054
          StateConfig : 19511054 NinjaTrader.NinjaScript.DrawingTools.RegionHighlig htY 6/23/2022 1:59:47 PM True
          Current State: Active Hash: 19511054
          Rendering : NinjaTrader.NinjaScript.DrawingTools.RegionHighlig htY 6/23/2022 1:59:50 PM True 688
          Rendering : NinjaTrader.NinjaScript.DrawingTools.RegionHighlig htY 6/23/2022 1:59:52 PM True 689
          Rendering : NinjaTrader.NinjaScript.DrawingTools.RegionHighlig htY 6/23/2022 1:59:55 PM True 690

          // reload occurred here

          Current State: SetDefaults Hash: 2367797
          StateDefault : 2367797 NinjaTrader.NinjaScript.DrawingTools.RegionHighlig htY 6/23/2022 1:59:57 PM False
          Current State: SetDefaults Hash: 2367797
          StateDefault : 2367797 NinjaTrader.NinjaScript.DrawingTools.RegionHighlig htY 6/23/2022 1:59:57 PM False

          // We see the new instance hit SetDefaults 2x, then we get the terminated update from the old instance.

          Current State: Terminated Hash: 19511054
          StateTerminate CS :19511054 NinjaTrader.NinjaScript.DrawingTools.RegionHighlig htY 6/23/2022 1:59:57 PM True

          // since State.Configure is not hit, we don't see the bool turn to true.

          Rendering : NinjaTrader.NinjaScript.DrawingTools.RegionHighlig htY 6/23/2022 1:59:57 PM False 690
          Rendering : NinjaTrader.NinjaScript.DrawingTools.RegionHighlig htY 6/23/2022 2:00:00 PM False 691
          My understanding is that this is also the case for bar types and chart styles.

          For your other script, right clicking on the chart actually creates an instance of every drawing tool to get their names to populate the Drawing Tools menu in the right click menu so this would be expected. I'd take a look at this page of the help guide on the NinjaScript Lifecycle:



          Please let us know if we may be of further assistance to you.
          Kate W.NinjaTrader Customer Service

          Comment


            #6
            Originally posted by NinjaTrader_Kate View Post
            // since State.Configure is not hit, we don't see the bool turn to true.

            Rendering : NinjaTrader.NinjaScript.DrawingTools.RegionHighlig htY 6/23/2022 1:59:57 PM False 690
            Rendering : NinjaTrader.NinjaScript.DrawingTools.RegionHighlig htY 6/23/2022 2:00:00 PM False 691

            1.) That is pretty much the point.. How/Why is State.Config not re-hit???

            2.) Is the lifecycle of a drawing tool different than an indy or strat???

            Default -> Configure -> Active/Processing -> Terminated

            Script should never get to Active/Processing state without hitting Config!


            Possibly I'm confused and/or mistaken, wouldn't be the first time.
            Please watch demonstration video linked below to hopefully help clarify.




            Please Advise???


            Attached Files
            -=Edge=-
            NinjaTrader Ecosystem Vendor - High Tech Trading Analysis

            Comment


              #7
              Hello -=Edge=-,

              Thank you for your reply.

              Strategies and indicators can load additional data, which is my understanding of why these would hit State.Configure. Since bar types, drawing tools, etc. cannot load additional data series, they would be expected to only hit State.Configure once in the lifetime of the object. I've got a request in to add a note on our page on OnStateChange to clarify this.



              Please let us know if we may be of further assistance to you.
              Kate W.NinjaTrader Customer Service

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by f.saeidi, Today, 11:02 AM
              1 response
              2 views
              0 likes
              Last Post NinjaTrader_BrandonH  
              Started by geotrades1, Today, 10:02 AM
              4 responses
              12 views
              0 likes
              Last Post geotrades1  
              Started by rajendrasubedi2023, Today, 09:50 AM
              3 responses
              16 views
              0 likes
              Last Post NinjaTrader_BrandonH  
              Started by lorem, Today, 09:18 AM
              2 responses
              11 views
              0 likes
              Last Post NinjaTrader_ChelseaB  
              Started by geddyisodin, Today, 05:20 AM
              4 responses
              30 views
              0 likes
              Last Post geddyisodin  
              Working...
              X