By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
428,558 Members | 1,607 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 428,558 IT Pros & Developers. It's quick & easy.

Uninstalling Windows Service With Deployment Project

P: n/a
I have created a small windows service in C# that installs using the
service installer classes and a deployment project. I have been able to
install the service but the uninstallation does not work. The files are
deleted from the application directory but the service is not being
unregistered.

The instructions I found did not indicate any code changes were
necessary, but I have found reference on Google to changing the
CanShutdown property in the service class but the results were the
same. The Installer completes the un-install process, but the service
still exists in the services list and the registry. The service is NOT
running during the unistallation.

Does anyone know what I have missed? There was reference in one posting
to properties called uninstall delete and uninstall shutdown, but I
have not found any other reference to these properties.

I have also seen refrences to using Installutil.exe from the framework
instead of using the service installer class.

Any help on this issue would be grand as I'm somewhat new to installers
and windows services.

Thanks in advance
Russ

Mar 24 '06 #1
Share this Question
Share on Google+
2 Replies


P: n/a
I suspect that you haven't added the custom action to the Uninstall actions.

You must add the custom action to all 4 actions.
<ru********@gmail.com> wrote in message
news:11**********************@t31g2000cwb.googlegr oups.com...
I have created a small windows service in C# that installs using the
service installer classes and a deployment project. I have been able to
install the service but the uninstallation does not work. The files are
deleted from the application directory but the service is not being
unregistered.

The instructions I found did not indicate any code changes were
necessary, but I have found reference on Google to changing the
CanShutdown property in the service class but the results were the
same. The Installer completes the un-install process, but the service
still exists in the services list and the registry. The service is NOT
running during the unistallation.

Does anyone know what I have missed? There was reference in one posting
to properties called uninstall delete and uninstall shutdown, but I
have not found any other reference to these properties.

I have also seen refrences to using Installutil.exe from the framework
instead of using the service installer class.

Any help on this issue would be grand as I'm somewhat new to installers
and windows services.

Thanks in advance
Russ

Mar 24 '06 #2

P: n/a
Do you have a source for this information? Everything I have looked
over failed to mention the need for custom actions at all. I was under
the impression that the ServiceInstaller and ServiceProcessInstaller
classes took care of all that was required?

Mar 27 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.