Is it normal behavior of VS 2015 ?
I am trying to store a value in appSettings in App.Config. In VS 2017, it gets stored in WindowsFormsApplication1.exe.config but it's not storing the value in VS 2015
My code is the same as in both the versions of VS.
var conf = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None);
var settings = conf.AppSettings.Settings;
settings.Add("password", textBox1.Text);
conf.Save(ConfigurationSaveMode.Modified);
ConfigurationManager.RefreshSection(conf.AppSettings.SectionInformation.Name);
And my App.config is this:
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.2" />
</startup>
<appSettings>
</appSettings>
</configuration>
Any explanation for this ?