Click here to Skip to main content
15,886,919 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Merhaba,

I have a question regarding your walkthrough how to create a windows service and deploy it with the setup project. It is very easy descriped and I want also to uninstall the service with the setup project but I just do not get it and find on this topic nothing useful on the Internet. You wrote:

Quote:
course you can use the Setup Project to uninstall the service but be careful to use the same Build which is used for installation. If you built solution, installed it and then rebuilded it again the Setup Project changes and cannot uninstall the service. In this situation you can keep the Setup file which is used for installation or just use Add or Remove Programs tool.


Can you please tell what I have to do to use the setup deployment to uninstall the service programmatically?

Thanks in advance,

Dogan

What I have tried:

I tried to use the controlservice class to stop the service programmatically in the uninstall method of the projectinstaller but it didn't work anyway.

A lot of research in the internet but didn't find anything useful about this topic
Posted
Comments
Mehdi Gholam 3-Aug-17 8:41am    
Try running the uninstall as administrator.
Richard Deeming 3-Aug-17 8:52am    
"regarding your walkthrough"

Whose walkthrough? There are over 13 million members here; who are you addressing this question to?

If you're asking about an article on this site, then you need to post your question in the discussion forum at the bottom of that article. That's the only way the author's going to see your question.
Member 13343454 3-Aug-17 16:21pm    
I thought I already done that... My question what I have to do to use the setup deployment to uninstall the service programmatically?
Richard Deeming 3-Aug-17 16:31pm    
You've posted a question to a general forum, asking about "your walkthrough".

As I said, there are over 13 million members here. You can't just say "you" and expect us to know who you're talking to!

There are also many thousands of articles here. "Your walkthrough on X" is not enough for anyone to work out which article you're talking about.

If you're asking a question about an article on this site, you need to use the discussion forum for that specific article. That is located at the bottom of the article, labelled "Comments and Discussions".

If the author of the article is no longer active, or doesn't respond within a reasonable time, then someone here might be able to help you. But you will need to tell us which article you're having problems with.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900