I'm trying to save some data at the runtime:
SettingsProperty property = new SettingsProperty("tabSetting");
property.Name = "tab";
property.PropertyType=typeof(string);
property.DefaultValue = "path";
Settings.Default.Properties.Add(property);
Settings.Default.Save();
but this code don't save any changes in file Settings.settings.
Also I try to make changes in Settings.settings from VisualStudio, I open this file and write settings by hand. After that I run the code which is mentioned above and get this exeption:
Item has already been added. Key in dictionary: 'tab' Key being added: 'tab'
Why Settings.Default.Save()
code is not working?