Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
NT8 Error: A hosted indicator tried to load additional data.
Collapse
X
-
I have resolved this issue by adding the following to my strategy code:Originally posted by fredb987 View PostPatrick H. - I am also having this issue starting today.
"A hosted indicator tried to load additional data. All data must first be loaded by the hosting NinjaScipt in its configure state."
Getting this on a strategy that uses the Pivots indicator. Per your instructions, I will email log and trace files. Thank you.
if (State == State.Configure)
{
AddDataSeries(BarsPeriodType.Day, 1);
}
Comment
-
I just had this issue but have now resolved it. If you refer to an indicator in another indicator and that hosted indicator has a secondary series in it, you need to include the secondary series from the hosted indicator in the hosted and the hosting indicator's if (State == State.Configure) section, like so in my case: AddDataSeries(BarsPeriodType.Tick, SecondaryDataSeriesValue). If you do not include it in the hosting indicator, the data will not be seen, hence the error.
From NT8 Manual Multi-Timeframe & Instruments:
Note: To maximize data loading performance, any NinjaScript object (indicator or strategy as host) which references a multi-series indicator which calls AddDataSeries must include it's own calls to AddDataSeries(). For example, if the code above was included in an indicator, and that indicator was referenced in a NinjaScript strategy, then the hosting strategy will need to include the same calls to AddDataSeries(). When the strategy adds the additional Bars objects, the calls to AddDataSeries() within the indicator will be ignored. If the Bars objects are not added by the strategy in such cases, and error will be thrown in the Log tab of the Control Center that would read - "A hosted indicator tried to load additional data. All data must first be loaded by the hosting NinjaScript in its configure state."Last edited by GeorgeW; 03-03-2017, 05:12 AM.
Comment
-
George
This is good information. It will keep me from this problem in the future.
However for me, its not the case for the occurrences I have had. I only get this
randomly and it sometimes happens when changing the days back of the data series in the UI.
Comment
-
Or, when changing trading hours, say from ETH to RTH, etc.Originally posted by JerryWar View PostGeorge
This is good information. It will keep me from this problem in the future.
However for me, its not the case for the occurrences I have had. I only get this
randomly and it sometimes happens when changing the days back of the data series in the UI.
Comment
-
There is also a related issue that has caused crashes. When the chart has two data series and my indicator adds in that 2nd series. If / when I remove the second series from the chart it crashes on random occasions. Kind of like the Add data series in the indicator locked itself to the Chart 2nd data series and didn't want to let go nicely.
Comment
-
All of the below i would agree can trigger this error and as tradesmart says
"changing trading hours, say from ETH to RTH, etc."
just including the standard indicator 'pivots' onto a chart triggers it
then you have the instance of some below when this is invoked from a strategy or another indicator.
Now this scenario introduces something that is either a bug on ninja indicator dependencies OR ninja need to stipulate in the help manual the conditions and requirements - but then it may not be obvious or clear unless clear in the interface that a 3rd party indicator indeed adds series internally - so you see the scope of this changes and what is and how should the underlying architecture be for this.
So indeed a number of scenarios contributing to this
Comment
-
Yes, I had also been having lots of crashes while using two data series on a chart, one hidden, so that I could overlay plots based on both the primary and secondary series. I have reverted to one data series and coded both time series plots into one indicator instead, and that aspect has run smoothly since.Originally posted by JerryWar View PostThere is also a related issue that has caused crashes. When the chart has two data series and my indicator adds in that 2nd series. If / when I remove the second series from the chart it crashes on random occasions. Kind of like the Add data series in the indicator locked itself to the Chart 2nd data series and didn't want to let go nicely.
Comment
-
This was my solution as well, One series on the chart and Multiple series in the indicator.Originally posted by GeorgeW View PostYes, I had also been having lots of crashes while using two data series on a chart, one hidden, so that I could overlay plots based on both the primary and secondary series. I have reverted to one data series and coded both time series plots into one indicator instead, and that aspect has run smoothly since.
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by argusthome, 03-08-2026, 10:06 AM
|
0 responses
88 views
0 likes
|
Last Post
by argusthome
03-08-2026, 10:06 AM
|
||
|
Started by NabilKhattabi, 03-06-2026, 11:18 AM
|
0 responses
48 views
0 likes
|
Last Post
|
||
|
Started by Deep42, 03-06-2026, 12:28 AM
|
0 responses
30 views
0 likes
|
Last Post
by Deep42
03-06-2026, 12:28 AM
|
||
|
Started by TheRealMorford, 03-05-2026, 06:15 PM
|
0 responses
34 views
0 likes
|
Last Post
|
||
|
Started by Mindset, 02-28-2026, 06:16 AM
|
0 responses
68 views
0 likes
|
Last Post
by Mindset
02-28-2026, 06:16 AM
|

Comment