Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Visual Studio Debugging

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

    Visual Studio Debugging

    Hello,
    While trying to debug the code of an custom indicator I receive the following error message in VS: System.ExecutionEngineException: "Exception of type 'System.ExecutionEngineException' was thrown." After this NT crashes.
    I use latest version of NT (8.0.16.3 64-bit) Visual Studio 2017 (15.9.4) and .NET (4.7.03056).
    For preparing debug I've strictly followed this instruction: https://ninjatrader.com/support/help..._debugging.htm.
    I've made sure to respect all steps, especially #4 ("Attach to" field is set to "Automatic: Managed code" or "Managed code").
    What can I do?

    #2
    Hello Knoppers,

    This happens when testing any script such as the SMA?

    Please send an email to platformsupport [at] ninjatrader [dot] com so that we may test the steps on your end.
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Hello Chelsea,
      yes, it happens while testing any script. I've just written you an email and looking forward to further assistance.

      Comment


        #4
        Has this issue been resolved? I'm experiencing a very similar issue. Whenever, I attempt to attache the latest version on the Visual Studio 2017 debugger to my running instance of NT 8, I receive the 'System.ExecutionEngineException: "Exception of type 'System.ExecutionEngineException' was thrown."' error and NT 8 crashes. The happens immediately upon attaching to the NT 8 process and before executing the script I am debugging.

        Comment


          #5
          The issue has been resolved, There were several pitfalls during troubleshooting, e.g.:
          - Wrong Visual Studio installation (“Universal Windows platform development” instead of “.NET desktop development”)
          - After an all new installation of NT8 according to the description of the Customer Service Team the behavior was better. But the current values of the variables weren't shown when I added some breakpoints.
          - I've got some log information in VS when NT was already disposed that the exception was caused by a third party add-on (TradingFuturoOrderFlow1.6.dll). After removing this NinjaScript Assambly debugging was working fine.

          Comment


            #6
            Thanks, Knoppers. This problem cropped up last week for me. I'll take a look at my own VS installation. Can you direct me to the VS log file that pointed you to the offending NinjaScript Assembly? I have a couple of new 3rd party extensions that may be causing this.

            Comment


              #7
              I was able to resolve this issue by uninstalling a third party add-on. This resolved the issue. Then, I was able to reinstall the add-on without the problem recurring. Thanks for your help!

              Comment


                #8
                Visual Studio 2022 (v 17.6.4) displays a message regarding "NinjaTrader.Gui.pdb not loaded" after I have launched it from the NinjaScript editor and followed the attach step on this page: https://ninjatrader.com/support/help..._debugging.htm I am running Ninja 8.0.28.0 64-bit

                Comment


                  #9
                  Hi Bruce, please make sure to right click the NinjaScript Editor>Enable "Debug Mode", then compile by pressing F5, then try Visual studio debugging after this.

                  Comment


                    #10
                    Chris, thank you for the response, however I had already done the right-click and enabled Debug Mode. I did it again just now, and still see the message regarding "NinjaTrader.Gui.pdb not loaded".
                    Bruce

                    Comment


                      #11
                      Hi, please first try uninstalling and re-installing Visual Studio. After this, please run a repair of your NinjaTrader installation by logging into your account page, downloading the latest installer and running it.

                      Comment

                      Latest Posts

                      Collapse

                      Topics Statistics Last Post
                      Started by argusthome, 03-08-2026, 10:06 AM
                      0 responses
                      65 views
                      0 likes
                      Last Post argusthome  
                      Started by NabilKhattabi, 03-06-2026, 11:18 AM
                      0 responses
                      41 views
                      0 likes
                      Last Post NabilKhattabi  
                      Started by Deep42, 03-06-2026, 12:28 AM
                      0 responses
                      23 views
                      0 likes
                      Last Post Deep42
                      by Deep42
                       
                      Started by TheRealMorford, 03-05-2026, 06:15 PM
                      0 responses
                      26 views
                      0 likes
                      Last Post TheRealMorford  
                      Started by Mindset, 02-28-2026, 06:16 AM
                      0 responses
                      52 views
                      0 likes
                      Last Post Mindset
                      by Mindset
                       
                      Working...
                      X