Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

OnRender Error on Bar -1 ?

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

    OnRender Error on Bar -1 ?

    Once or twice a day I have been getting this error:

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

    Despite my error trapping, the indicator disappears from the chart until I hit F5, and then eveyrthing is OK.

    The indicator is on 10 different charts, but the error always occurs on only one chart, never on the others.

    Apart from not knowing how to correct the error, I don't understand what a reference to "bar -1" could be.

    Any help would be appreciated.

    #2
    Hello palinuro,

    Thanks for your post.

    If it happens on only one chart then it sounds like you have a repeatable condition to test with. Is it possible that your code for a barsago reference could be using -1 or some other negative value? You could test for this using various print statements in your code.
    Paul H.NinjaTrader Customer Service

    Comment


      #3
      Thanks for the response. I spoke too soon, t's now happening occasionally other charts as well (2 separate charts today, once each over about 7 hours).

      It's a new error, and the indicator hasn't been changed, so I'm not sure it's repeatable- but I'll try to output anything that might be creatiing a bar -1 error.

      But still, if that's the case, I would think my error trapping should prevent the indicator from vanishing, as it does in case of other errors.

      I have run a memory check, since the message refers to possible problems, but it didn't find anything.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Mokaru Zen, Today, 01:20 AM
      1 response
      10 views
      0 likes
      Last Post NinjaTrader_Jason  
      Started by dgee949, Yesterday, 06:26 PM
      1 response
      38 views
      0 likes
      Last Post NinjaTrader_Jason  
      Started by dgee949, Yesterday, 05:58 PM
      1 response
      40 views
      0 likes
      Last Post NinjaTrader_Jason  
      Started by papaoutai, Yesterday, 08:56 AM
      1 response
      42 views
      0 likes
      Last Post NinjaTrader_Jason  
      Started by grzltn, Today, 02:18 AM
      0 responses
      21 views
      0 likes
      Last Post grzltn
      by grzltn
       
      Working...
      X