I am using the app.config file to read data from it. I load the app.config file as:
string app_path = HttpContext.Current.Server.MapPath("app.config"); xmlDoc.Load(app_path); string image_path = ConfigurationManager.AppSettings["Test1"];
and I want to get the value "Test1". But the value of test1 starts with "null". how can I get the value "test1" from the app.config file .. I created the app.config file as:
<?xml version="1.0" encoding="utf-8"?> <configuration> <appSettings> <add key="Test1" value="My value 1" /> <add key="Test2" value="Another value 2" /> </appSettings> </configuration>
please help me.
percy source share