After changing the value of ApplicationSettings
in web.config
, the data of Settings.Default
doesn't update.
I try to call
Settings.Default.Reload();
but it does not work.
Values update only after I open project settings in Visual Studio.
How can I update Settings.Default
values in run-time? Is this possible?
Solved
Alright, values are updated! The problem was that I tried to get the value from Settings.Default.Properties["Key"].DefaultValue
, which means to get the default value that is stored in settings.settings
. To get the updated value, you must use Settings.Default.Key
property.