Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Weird bug, likely due to an indicator I've created, with blank chart.

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

    Weird bug, likely due to an indicator I've created, with blank chart.

    Hello.

    I've come across an error, that only occurs when I use up to 8-9 charts, and that is a blank chart. The data is still there, but the chart is just empty. I know the chart is still there, as if I click and hold any part of the area shown in the image(boxed in area), the data will show up.

    I suspect it is due to something I've used incorrectly with onRender(), and am trying to narrow down the issue. I think I've disposed on various strokes properly?

    Another potential issue, is that I have an indicator where I add multiple different symbols to in State.Configure, so that is also a potential issue.

    So I'm just wondering if there is a KNOWN mis-use of something that will cause this error? This does not seem to happen if I just have 2-4 charts open.

    I see no errors in the log, or any errors in the output window. I've recreated my workspace with 9 charts, with no indicators, and am adding one at a time, attempting to find the error and recreate it, but it doesn't always happen right away.
    Attached Files

    #2
    Hi forrestang, thanks for your post.

    I could not think of a reason this would only fail at 8-9 charts.

    Please send me your log and trace files so that I may look into what occurred.

    You can do this by going to the Control Center-> Help-> Email Support

    Ensuring 'Log and Trace Files' is checked will include these files. This is checked by default.

    Please reference the following ticket number in the body of the email: 3102719 Attn ChrisL
    Chris L.NinjaTrader Customer Service

    Comment


      #3
      Also of note, the trace file I sent, was likely after restarting NT, and NOT seeing that error.

      I am unsure if the trace file will hold states of prior NT sessions I may have had open?

      So would I need to have a trace file sent, at the time I notice the error?

      Comment


        #4
        Hi, thanks for sending that

        The trace files folder adds a trace file every time you open NinjaTrader.

        You are getting this error in the trace files, if this is the correct indicator then it could cause a blank chart window if the OnRender method is not working properly:

        ERROR: Indicator 'PriceLineScrollable': Error on calling 'OnRender' method on bar 5612: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.

        This subject has been discussed in this forum thread:

        https://ninjatrader.com/support/foru...otected-memory

        Also, see the best practices for working with SharpDX brushes here to see if this applies to your code:

        https://ninjatrader.com/support/help...arpDXResources

        Best regards,
        -ChrisL
        Last edited by NinjaTrader_ChrisL; 05-14-2021, 03:34 PM.
        Chris L.NinjaTrader Customer Service

        Comment


          #5
          Originally posted by NinjaTrader_ChrisL View Post
          Hi, thanks for sending that

          The trace files folder adds a trace file every time you open NinjaTrader.

          You are getting this error in the trace files, if this is the correct indicator then it could cause a blank chart window if the OnRender method is not working properly:

          ERROR: Indicator 'PriceLineScrollable': Error on calling 'OnRender' method on bar 5612: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.

          This subject has been discussed in this forum thread:

          https://ninjatrader.com/support/foru...otected-memory

          Also, see the best practices for working with SharpDX brushes here to see if this applies to your code:

          https://ninjatrader.com/support/help...arpDXResources

          Best regards,
          -ChrisL
          Ah... that error was me attempting to try to change something... AFTER I got the blank screen. I was just playing around with the OnRenderTargetChanged() function.

          I thought maybe I had an issue with not disposing of some brush, but was not the case.

          So if that is confusing... essentially I created that error AFTER this blank screen bug popped up.

          Comment


            #6
            Hi, thanks for your reply.

            Do you get this on any other indicator like the SampleCustomRender indicator or only when you use your indicator? If you add Prints to the OnRender method do you see it stop printing when this happens to the chart? Also make sure you have the latest drivers for your video card installed and are not using anything like a monitor connected through USB (adapter).

            Best regards,
            -ChrisL
            Chris L.NinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by selu72, Today, 02:01 PM
            0 responses
            0 views
            0 likes
            Last Post selu72
            by selu72
             
            Started by f.saeidi, Today, 12:14 PM
            8 responses
            18 views
            0 likes
            Last Post f.saeidi  
            Started by Mikey_, 03-23-2024, 05:59 PM
            3 responses
            49 views
            0 likes
            Last Post Sam2515
            by Sam2515
             
            Started by Russ Moreland, Today, 12:54 PM
            1 response
            7 views
            0 likes
            Last Post NinjaTrader_Erick  
            Started by philmg, Today, 12:55 PM
            1 response
            8 views
            0 likes
            Last Post NinjaTrader_ChristopherJ  
            Working...
            X