How to cleanup the user settings file on uninstall?

231 Views Asked by At

When using Settings.settings when an user changes a setting it saves it to:

%AppData%\Local\Microsoft\%ProcessName%_Url_%hashCode%\%version%\user.config

For an InnoSetup uninstaller it is very difficult to clean all those files.

Isn't there an easier way?

1

There are 1 best solutions below

3
On BEST ANSWER

There is a way to change where the ms config stuff writes settings, but after researching it, I ended up just avoiding the MS settings stuff (except for the app.exe.config file that's in the same folder as the exe itself) and just used XML serialization to serialize\deserialize my own settings object into an appropriate \AppData\Folder.