Wednesday, July 30, 2008

How to Debug the Installation of Windows Service

Just setup in your Debug tab of your Visual Studio Windows Service project:

· Select Start external program” and find InstallUtil.exe (usually under <Windows\Microsoft.NET>)

· Then as command line argument put the name of your executable

· As a working directory, select the output folder of your project

It should look like this:


Setup the breakpoints and hit F5. The installation should start and stop at your breakpoint.

The service might be not be completely installed or removed. If that is the case, just use in a command line window installUtil /u <path:filename of your executable>

No comments: