Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

A hosted indicator tried to load additional data. ( FYI )

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

    A hosted indicator tried to load additional data. ( FYI )

    "A hosted indicator tried to load additional data. All data must first be loaded by the hosting NinjaScript in its configure state."

    I used to get this message back in my indicator building days and I just came across this possible explanation in the NT8 Guide. If you are receiving this message, this might be why:

    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."




    #2
    Hello NickyD,

    This error is caused if any hosted scripts (such as an indicator that is called from another script), adds additional series with AddDataSeries() but the host script that calls it does not add the same additional series.

    The error means that you will also need to add that exact same series to the host script (or calling strategy or indicator).
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      I have this error since rolling the contracts in the Add() array from 03-20 to 06-20 by simply typing in the new contract code in the Add() series. Never came across this error before. Strategy worked with the 03-20 label - but changing to the 06-20 label causes this error. Need rapid response please. Regards


      else if (State == State.Configure)
      {

      ////Data Series added to array

      //US Equity Futures
      AddDataSeries("ES 06-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 405 }, "CME US Index Futures RTH");
      AddDataSeries("YM 06-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 405 }, "CME US Index Futures RTH");
      AddDataSeries("NQ 06-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 405 }, "CME US Index Futures RTH");
      AddDataSeries("RTY 06-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 405 }, "CME US Index Futures RTH");

      AddDataSeries("MES 06-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 405 }, "CME US Index Futures RTH"); // 5
      AddDataSeries("MYM 06-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 405 }, "CME US Index Futures RTH");
      AddDataSeries("MNQ 06-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 405 }, "CME US Index Futures RTH");
      AddDataSeries("M2K 06-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 405 }, "CME US Index Futures RTH");

      // US ON Futures
      AddDataSeries("MES 06-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 945 }, "CME Index Futures Night"); // 9
      AddDataSeries("MYM 06-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 945 }, "CME Index Futures Night");
      AddDataSeries("MNQ 06-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 945 }, "CME Index Futures Night");
      AddDataSeries("M2K 06-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 945 }, "CME Index Futures Night");


      // Bond Futures
      AddDataSeries("ZB 06-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 400 }, "CBOT Interest Rate RTH"); // 13
      AddDataSeries("ZN 06-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 400 }, "CBOT Interest Rate RTH");

      // Gold Futures
      AddDataSeries("QO 04-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 310 }, "Nymex Metals RTH2");

      // Oil Futures
      AddDataSeries("QM 04-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 330 }, "Nymex Energy RTH"); // 16
      AddDataSeries("CL 04-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 330 }, "Nymex Energy RTH");
      AddDataSeries("CL 04-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 1110 }, "Nymex Energy Night");
      // Europe Futures
      AddDataSeries("FESX 03-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 540 }, "Euronext GMT Index Futures RTH2"); // line 2952

      // Asia Futures
      AddDataSeries("NKY 06-20", new BarsPeriod { BarsPeriodType = BarsPeriodType.Minute, Value = 375 }, "SGX Nikkei Index Futures");
      Last edited by elliot5; 03-12-2020, 03:05 AM.

      Comment


        #4
        Hello elliot5,

        Did you make sure the AddDataSeries() calls match in both scripts?

        Does the indicator run by itself without error on a chart?
        Chelsea B.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Geovanny Suaza, 02-11-2026, 06:32 PM
        0 responses
        648 views
        0 likes
        Last Post Geovanny Suaza  
        Started by Geovanny Suaza, 02-11-2026, 05:51 PM
        0 responses
        369 views
        1 like
        Last Post Geovanny Suaza  
        Started by Mindset, 02-09-2026, 11:44 AM
        0 responses
        109 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Started by Geovanny Suaza, 02-02-2026, 12:30 PM
        0 responses
        573 views
        1 like
        Last Post Geovanny Suaza  
        Started by RFrosty, 01-28-2026, 06:49 PM
        0 responses
        575 views
        1 like
        Last Post RFrosty
        by RFrosty
         
        Working...
        X