I want to retrieve a value from my <appSettings> section in my web.config file. The key is named imgServer.
I tried this but it doesn’t work:
Label1.Text = System.Configuration.ConfigurationSettings.AppSettings.Get("imglServer");
I then tried:
Label1.Text = ConfigurationSettings.AppSettings["imgServer"];
But this doesn’t work either.
What am I doing wrong?
Try that.