Is here someone which can give me an example of a code which I can use to set and get values of variables in my settings file?
get and set values of variables in settings file
Collapse
X
-
Tags: None
-
- In project properties > Settings
- create a property with Name as USER and Type as String.
To set and get this property use below code:
Code://Store value in USER property from txtUser TextBox Properties.Settings.Default.USER = txtUser.Text; Properties.Settings.Default.Save(); //Read USER property in a variable username string username = Properties.Settings.Default.USER;
-
Comment