I am using C#’s XML application settings for my Windows Form. Whenever I release a new version of the program, the user has to re-enter the settings because the settings will now be read from a new path.
The path looks like this:
%LOCALAPPDATA%\<program name>\<program name>._Url_<a random string>\<version>\user.config
What I want to be able to do is either have it so I can set the path of the settings myself so they do not get reset, is this possible? If so, how would I go about doing this?
Check the ApplicationSettingsBase.Upgrade metod
I found this on MSDN. It will read existing setting values from old version. I have tested with a helloword winforms app and my “Option1” setting was kept after version upgrade.