Archive: Uninstall: deleting only installed files


Uninstall: deleting only installed files
Hello all,

till now I'm using "RMDir /r" during the uninstall process to delete the install directory.
The problem with that is if the user stores some data in the folder, it will be lost by uninstall.

Is there an automatic way to remove only those files which have been installed and leave the others there?

Any help welcome,

thanks,

Guilhem.


Ofcource, individually dlete the files, then to a RMDIR.

Not that RMDIR can be used without R then it deleted the folder only if it is empty.

See snip example below:

;When installing APP it's in StrCpy $INSTFOLDER "$PROGRAMFILES\$CompanyRootFolder\$TargetMarketMainFolderGlobal\$MainFolder"

; Remove files and uninstaller individually
Delete /REBOOTOK "$INSTFOLDER\MYMAIN.EXE"
Delete /REBOOTOK "$INSTFOLDER\extra.dll"
Delete /REBOOTOK "$INSTFOLDER\uninst.exe"

Setoutpath "$PROGRAMFILES"

RMDir /REBOOTOK "$PROGRAMFILES\$CompanyRootFolder\$TargetMarketMainFolderGlobal" ;only deletes if there are no more applications is sub folder
RMDir /REBOOTOK "$PROGRAMFILES\$CompanyRootFolder" ;only deletes anyhow if there are no more old other3rd party applications


http://forums.winamp.com/showthread....hreadid=213182
http://nsis.sourceforge.net/Uninstal...nstalled_files


Thanks a lot guys.