Monday, July 18, 2011

Removing A Windows Service No Longer In Add/Remove Programs

So the Visual Studio 2010 installer projects for Windows Services make me more and more frustrated every time something odd crops up.  This time, I began getting error messages during installation saying something like the service couldn't be started from the command line... wha?  So I deleted the ProjectInstaller.cs and re-added it, and this time during the install I didn't get that error message *and* it asked me for the user under which the service should run (which it wasn't doing).  But then it gave me an error saying that the service already existed.

And here's the pain: the service was still showing up in the Services control panel, but it was no longer showing up in the Add or Remove Programs control panel.  Ugh.  Googling to the rescue:


The use of the command-line "sc" program worked just fine:

sc delete "service name"

did the trick.

No comments:

Post a Comment