Debugging Windows Installer Custom Actions

General

  1. First, you must know the name of the custom action you want to debug. In this example we’ll call it MyCustomAction.
  2. Set the MsiBreak environment variable (user or system) to the name of the custom action. You can do this easily by running setx from the commandline:

    C:\Windows\System32>setx MsiBreak MyCustomAction
    SUCCESS: Specified value was saved.
    C:\Windows\System32>

  3. Run your installer

You should get now get a message box prompt like this:

image

At this point, you can use Visual Studio or another debugger such as WinDBG to attach to the specified process.

Leave a Reply

 

 

 

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>