I have made an exefile with winforms and I want to read/write settings to the exefiles configuration. But how can I do it? I'm using Visual Studio 2013. Is there differences between Visual Studio 2013 and 20196?
I have tried the following in c# but I couldn't find Configuration, ConfigurationManager and ConfigurationSaveMode - so what do I need to using?
Configuration config = ConfigurationManager.OpenExeConfiguration(Application.ExecutablePath);
config.AppSettings.Settings.Remove("CountryCode");
config.AppSettings.Settings.Add("CountryCode", "+45");
config.AppSettings.Settings.Remove("MobilePhone");
config.AppSettings.Settings.Add("MobilePhone", "12345678");
config.Save(ConfigurationSaveMode.Modified);