Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Trying to load indicator: Is a method but is used like a type

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

    Trying to load indicator: Is a method but is used like a type

    Hey fellas -

    I'm trying to load this indicator into my custom strategy but I get this error on compiling. What does it mean as this is the first time I've had this issue with any indicator?

    NinjaScript File Error Code Line Column
    TestScript.cs 'NinjaTrader.NinjaScript.Strategies.Strategy.amaTr adersDynamicIndex(int, int, int, int, double)' is a 'method' but is used like a 'type' CS0118 33 11

    I've attached my simple test script and the indicator code.

    Thanks!
    Attached Files

    #2
    Hello PN720,
    Thanks for your post.

    Change the way you are instantiating the indicator from
    Code:
    private amaTradersDynamicIndex TDIInd;
    to
    Code:
    private Indicators.LizardIndicators.amaTradersDynamicIndex TDIInd;
    You need to do this when you are calling your indicators from a folder.
    Josh G.NinjaTrader Customer Service

    Comment


      #3
      Ah, makes sense, thanks again!

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by NullPointStrategies, Today, 05:17 AM
      0 responses
      50 views
      0 likes
      Last Post NullPointStrategies  
      Started by argusthome, 03-08-2026, 10:06 AM
      0 responses
      126 views
      0 likes
      Last Post argusthome  
      Started by NabilKhattabi, 03-06-2026, 11:18 AM
      0 responses
      69 views
      0 likes
      Last Post NabilKhattabi  
      Started by Deep42, 03-06-2026, 12:28 AM
      0 responses
      42 views
      0 likes
      Last Post Deep42
      by Deep42
       
      Started by TheRealMorford, 03-05-2026, 06:15 PM
      0 responses
      46 views
      0 likes
      Last Post TheRealMorford  
      Working...
      X