Why doesn't installaware's uninstall not delete folders

Got a problem you cannot solve? Try here.
Post Reply
PShah
Posts: 10
Joined: Tue Feb 13, 2007 12:26 pm

Why doesn't installaware's uninstall not delete folders

Post by PShah »

When I uninstall my product, all the files I installed get deleted, but the folders that the installer created for them do not. They get left as empty folders, even if nothing beyond the original install was added to them. Is this behavior configurable?

Thanks.
MichaelNesmith
Posts: 3452
Joined: Thu Dec 22, 2005 7:17 pm
Contact:

Post by MichaelNesmith »

These folders are automatically deleted - you can try with a generic project and see that this works.

I think in your case you may have another program still using these folders, thus maybe they are locked and not removed. Try seeing what happens after a reboot.

If you want to try to force a delete, try to use Delete Files Recursive, or Call DLL Function on RemoveDirectoryA in kernel32.dll.
Michael Nesmith
Install[b]Aware[/b]
[i]Home of The Next Generation MSI Installer[/i]
Get your free copy today - http://www.installaware.com/
PShah
Posts: 10
Joined: Tue Feb 13, 2007 12:26 pm

deleting folders

Post by PShah »

You mean I should explicitly use those commands in the MSI script? I'm not sure where exactly I need to put code for it to be executed on uninstall. I suppose I could just put inside an 'if REMOVE' block?
MichaelNesmith
Posts: 3452
Joined: Thu Dec 22, 2005 7:17 pm
Contact:

Post by MichaelNesmith »

Yes, you can do that. Your situation is not typical, normally you do not need to do manual removal. But it might be easier for you to delete folders by brute force rather than identify the cause.
Michael Nesmith
Install[b]Aware[/b]
[i]Home of The Next Generation MSI Installer[/i]
Get your free copy today - http://www.installaware.com/
Post Reply