Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Run Time Error

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

    Run Time Error

    Hello.

    I'm getting the following message when I load my new indicator,

    "Failed to call method 'Initialize' for indicator 'rcsGomArrows': Object reference not set to an instance of an object."

    What am I missing?

    Thanks.

    #2
    Hi rcsingleton,

    Thank you for your post.

    This is a common programming error, that likely is a result from an error in the coding.
    What version of NinjaTrader are you using? (Control Center>Help>About)

    If you are not the creator of this indicator, please contact the creator so that they can resolve the issue by making the appropriate changes to the code.
    TimNinjaTrader Customer Service

    Comment


      #3
      I'm the creator of the indicator.

      I'm using NT 7.0.1000.2

      Comment


        #4
        Hi rcsingleton,

        The error indicates that something within the Initialize block is trying to reference something, but it does not exist or needs to be corrected. You'll need to narrow down which part of your code is causing the error, and make the necessary changes.

        You can try using Print()'s or even Try/Catch blocks:



        If you are still unable to identify section of the code, you can post it here and I will take a quick look myself.
        TimNinjaTrader Customer Service

        Comment


          #5
          I discovered the source of that message and its gone.

          The indicator is still not working and I see the following message under the "debug" version of the code in Visual Studio.

          A first chance exception of type 'System.IO.EndOfStreamException' occurred in mscorlib.dll.


          This is a DLL in both Silverlight and .NET framework.

          I have Silverlight 4.0.51204.0 and .NET Framework v4.0.

          Is there an issue with my current version of NT and the above two programs?

          Comment


            #6
            Hi rcsingleton,

            What version of NinjaTrader are you using?
            This does not look to be a NinjaTrader specific issues, you can try repairing the .Net framework, but for your indicator, you'll need to dig deeper for the cause. Have you been able to prompt any other error or specific behaviors when running the indicator?
            TimNinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by Hwop38, 05-04-2026, 07:02 PM
            0 responses
            164 views
            0 likes
            Last Post Hwop38
            by Hwop38
             
            Started by CaptainJack, 04-24-2026, 11:07 PM
            0 responses
            318 views
            0 likes
            Last Post CaptainJack  
            Started by Mindset, 04-21-2026, 06:46 AM
            0 responses
            246 views
            0 likes
            Last Post Mindset
            by Mindset
             
            Started by M4ndoo, 04-20-2026, 05:21 PM
            0 responses
            350 views
            0 likes
            Last Post M4ndoo
            by M4ndoo
             
            Started by M4ndoo, 04-19-2026, 05:54 PM
            0 responses
            179 views
            0 likes
            Last Post M4ndoo
            by M4ndoo
             
            Working...
            X