I want to uninstall the previously installed application and its associated files and folders before installing the new one.
I referred this solution Detect and uninstall old version of application in Inno Setup using its version number stored in registry – this is working fine, but not removing files and folders which was created by previously installed version.
Example: User has the old version in c:\test\my program
and now if he changes the location directly into c
. Then it should delete the old files and folders which are present in c:\test
. Any way to do that?