How to Disable the JIT Debugger "cordbg.exe"

Posted on 2006-04-05
Last Modified: 2011-08-18
I am trying to find a way to remove the "cordbg.exe" reference from my application (if possibly) so I do not get an error that the JIT Debugger can not be found when running the application on a machine that does not have the cordbg.exe program to call when the application starts.

Is this possible or do I need this to run on every computer that uses my application ?

I think that if I install the .net sdk on the machines then it will install the cordbg.exe program but I do not want to have to install the SDK on every machine or do I need too.

Question by:teamels
    LVL 32

    Expert Comment

    This is the debugger for "exceptions of last resort".  The solution is to catch all possible exceptions in your code so that the debugger never gets called.  If you are seeing this, you have unhandled exceptions in your code...

    Author Comment

    If there were unhandeled exceptions wouldnt Visual Studio catch this upon bulding the solution?
    If I have an exception visual studio so far sees this and does not let the program build and also lets me see where the exception took place and a suggestion on how to correct this.

    Do we need to call the cordbg.exe JIT Debugger to run even if the program seems to run just fine.


    Author Comment

    If it can't be disabled then how do we install the bloody bugger ? on client machines already running .NET V1.1

    LVL 32

    Accepted Solution

    No, there is no requirement at handle all exceptions.  That's why Windows catches anything you don't catch.

    Once again, catch ALL possible exceptions in your code and you won't need any JIT debugger.  This is not as hard as it sounds.  Just enclose the top level function in your application in a try/catch block.  You don't have to actually do anything other than catch the exception.  You can just output an error and exit, or whatever you want.

    Author Comment

    I see now.  I placed the Try, Catch, Finally in the below section, which I never thought to do because it was pre-generated code by Visual Studio.  This shows that I have a reference to a .VB file that is only installed on my development computer, not any others.

    #Region " Windows Form Designer generated code "

        Public Sub New()


                'This call is required by the Windows Form Designer.


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Looking for New Ways to Advertise?

    Engage with tech pros in our community with native advertising, as a Vendor Expert, and more.

    Suggested Solutions

    Title # Comments Views Activity
    scoresAverage challenge 8 58
    WiX Installer 2 39
    mapAB Challlenge 35 50
    delphi parse string to params 3 45
    This article will show, step by step, how to integrate R code into a R Sweave document
    Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
    An introduction to basic programming syntax in Java by creating a simple program. Viewers can follow the tutorial as they create their first class in Java. Definitions and explanations about each element are given to help prepare viewers for future …
    In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …

    737 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    15 Experts available now in Live!

    Get 1:1 Help Now