Home All Groups Group Topic Archive Search About

Configuration Obsolete method

Author
8 Nov 2005 6:58 AM
Robert Beaubien
My converted application is generating warnings for the following line, but
I can not find any system.configuration.configurationManager.AppSettings
items.  What am I missing?
SqlConnection1.ConnectionString =
System.Configuration.ConfigurationSettings.AppSettings.Get("ConnectionPrimary")

Warning 13 'Public Shared ReadOnly Property AppSettings() As
System.Collections.Specialized.NameValueCollection' is obsolete: 'This
method is obsolete, it has been replaced by
System.Configuration!System.Configuration.ConfigurationManager.AppSettings'
D:\VS2005\Projects\NVC\NVCArmls\ArmlsDAL\ArmlsUsers.vb 22 43 ArmlsDAL

Author
9 Nov 2005 10:08 AM
Michael Höhne
Robert,

You must add a reference to the System.Configuration assembly in your
project settings, then you will see the ConfigurationManager class.

Michael

Show quote
"Robert Beaubien" <rbeaub***@koolsoft.com> schrieb im Newsbeitrag
news:%23lCXmHD5FHA.3276@TK2MSFTNGP10.phx.gbl...
> My converted application is generating warnings for the following line,
> but I can not find any
> system.configuration.configurationManager.AppSettings items.  What am I
> missing?
> SqlConnection1.ConnectionString =
> System.Configuration.ConfigurationSettings.AppSettings.Get("ConnectionPrimary")
>
> Warning 13 'Public Shared ReadOnly Property AppSettings() As
> System.Collections.Specialized.NameValueCollection' is obsolete: 'This
> method is obsolete, it has been replaced by
> System.Configuration!System.Configuration.ConfigurationManager.AppSettings'
> D:\VS2005\Projects\NVC\NVCArmls\ArmlsDAL\ArmlsUsers.vb 22 43 ArmlsDAL
>
>
Author
9 Nov 2005 2:13 PM
Robert Beaubien
That did the trick.  I didn't even think of that.

Thanx,

--
- Robert Beaubien
- President
- Kool Software
-
Show quote
"Michael Höhne" <michael.hoehne@nospam.nospam> wrote in message
news:OK40$UR5FHA.1416@TK2MSFTNGP09.phx.gbl...
> Robert,
>
> You must add a reference to the System.Configuration assembly in your
> project settings, then you will see the ConfigurationManager class.
>
> Michael
>
> "Robert Beaubien" <rbeaub***@koolsoft.com> schrieb im Newsbeitrag
> news:%23lCXmHD5FHA.3276@TK2MSFTNGP10.phx.gbl...
>> My converted application is generating warnings for the following line,
>> but I can not find any
>> system.configuration.configurationManager.AppSettings items.  What am I
>> missing?
>> SqlConnection1.ConnectionString =
>> System.Configuration.ConfigurationSettings.AppSettings.Get("ConnectionPrimary")
>>
>> Warning 13 'Public Shared ReadOnly Property AppSettings() As
>> System.Collections.Specialized.NameValueCollection' is obsolete: 'This
>> method is obsolete, it has been replaced by
>> System.Configuration!System.Configuration.ConfigurationManager.AppSettings'
>> D:\VS2005\Projects\NVC\NVCArmls\ArmlsDAL\ArmlsUsers.vb 22 43 ArmlsDAL
>>
>>
>
>

AddThis Social Bookmark Button