Hi,
Whenever we read values from configuration, the people who worked on earlier versions of .net has a habit of writing the below line of code for reading values from configuration.
string strValue = System.Configuration.ConfigurationSettings.AppSettings["KeyValue"];
The fix is very simple, just add System.Configuration as reference to your project and change ConfigurationSettings to ConfigurationManager. You don't see any warning now.
Hope this helps.
--
Happy Coding
Gopinath
Whenever we read values from configuration, the people who worked on earlier versions of .net has a habit of writing the below line of code for reading values from configuration.
string strValue = System.Configuration.ConfigurationSettings.AppSettings["KeyValue"];
The fix is very simple, just add System.Configuration as reference to your project and change ConfigurationSettings to ConfigurationManager. You don't see any warning now.
string strValue = System.Configuration.ConfigurationManager.AppSettings["KeyValue"];
Hope this helps.
--
Happy Coding
Gopinath
No comments:
Post a Comment