The indicator defines 7 different plots, and updates them in the standard way. It does not implement the OnRender() method, nor does it inherit any implementation of that method except for the one implemented in the base class written by NinjaTrader. It also does not attempt to draw anything other than by setting the values of the data series for the seven plots.
The indicator was ported from NinjaTrader 7, where it has been working without any errors for over two years of round-the-clock use on 6 different instruments.
The indicator also passes every test of long term use on NinjaTrader 8--but only when used in MarketReplay mode.
However, when used in NT8 on real time data (Kinetick; 6E, CL, ES, GC, NQ, TF, YM) the error in the title eventually occurs, usually after just a few minutes of operation, although we've seen it take over an hour.
Here's the relevant text from the log file:
2015-11-01 15:03:39:522|3|4|A direct X error has occured while rendering the chart: HRESULT: [0x88990001], Module: [SharpDX.Direct2D1], ApiCode: [D2DERR_WRONG_STATE/WrongState], Message: The object was not in the correct state to process the method.
2015-11-01 15:03:39:532|3|16|Chart rendering failed. There is likely a problem with a chart object's OnRender method. D2D error = 'HRESULT: [0x88990001], Module: [SharpDX.Direct2D1], ApiCode: [D2DERR_WRONG_STATE/WrongState], Message: The object was not in the correct state to process the method. '
And here's the relevant text from the trace file:
2015-11-01 15:03:39:529 ERROR: A direct X error has occured while rendering the chart: HRESULT: [0x88990001], Module: [SharpDX.Direct2D1], ApiCode: [D2DERR_WRONG_STATE/WrongState], Message: The object was not in the correct state to process the method.
2015-11-01 15:03:39:533 ERROR: Chart rendering failed. There is likely a problem with a chart object's OnRender method. D2D error = 'HRESULT: [0x88990001], Module: [SharpDX.Direct2D1], ApiCode: [D2DERR_WRONG_STATE/WrongState], Message: The object was not in the correct state to process the method. '
Based on all the facts and evidence. it seems highly likely that the error is either a bug in the SharpDX code itself, or else is in the logic of the OnRender() method implemented by NinjaTrader.
I have attached the log and trace files.
Comment