Windows Develop Bookmark and Share   
 index > ClickOnce and Setup & Deployment Projects > Delete all files and folder while Uninstalling the setup
 

Delete all files and folder while Uninstalling the setup

Hi,

My software ABC creating folders ABC in instaling directory.

When i uninstalling folders and some of the files like config and some dlls not removing from that directory.

Because of these cause next time when installing files are not over write on this folder.

Is there any way or idea to remove whole folders from that directory while uninstalling the our software?


Thanks in Advance
Kalees.
Kaleeswara Murthy  Wednesday, September 30, 2009 8:04 PM
Hi Kaleeswara,

From my experience, we can add a custom action to delete files when the program is uninstalled. We need to put the files deleting code in the Uninstall method of the custom Installer class. This is a walkthrough: http://msdn.microsoft.com/en-us/library/d9k65z2d(VS.80).aspx
This is a sample: http://www.codeproject.com/KB/install/AddinCustomAction.aspx

Regards,
Aland Li
Please mark the replies as answers if they help and unmark if they don't. This can be beneficial to other community members reading the thread.
Aland Li  Monday, October 05, 2009 10:13 AM
Hi Kaleeswara,

From my experience, we can add a custom action to delete files when the program is uninstalled. We need to put the files deleting code in the Uninstall method of the custom Installer class. This is a walkthrough: http://msdn.microsoft.com/en-us/library/d9k65z2d(VS.80).aspx
This is a sample: http://www.codeproject.com/KB/install/AddinCustomAction.aspx

Regards,
Aland Li
Please mark the replies as answers if they help and unmark if they don't. This can be beneficial to other community members reading the thread.
Aland Li  Monday, October 05, 2009 10:13 AM

You can use google to search for other answers

Custom Search

More Threads

• Streaming Files from Binary Files Table in MSM
• Must reinstall ClickOnce application each time - same version
• ClickOnce deployment installs .NET 3.5 from web instead of .NET 2.0 from deployment site
• WPF application clickonce deployment problem
• USERPROFILE variable blank
• What is new in "Visual Studio 2008" for "Setup and Deployment Project"?
• How to Revert Back to any version Required
• Mage tool changes not being downloaded to user PCs
• Web project - Force Restart
• Click Once Deployment options - Help Needed