Home All Groups Group Topic Archive Search About

Darn, still does not work!

Author
28 Jan 2006 10:36 PM
Bob
Vs2003, Winform app, trying to read an application setting

Dim MyAppMgr as new System.configuration.AppsettingsReader
Me.textbox1.text = MyAppMgr.Getvalue("MyServerName",string)
Now when I execute the first line I get a system.dll exception because it
says required attiubte 'Value' not found.

What value, there are no choices possibles either as other objects or as
parameters for AppsettingsReader in intellisense. If I don't include the
word new in the line obviously MyappMgr object stays to nothing and the next
line gives me an error.

How do I get out of this friggin catch 22.

Any help appreciated.

Bob

Author
28 Jan 2006 11:22 PM
I Don't Like Spam
Bob wrote:
Show quoteHide quote
> Vs2003, Winform app, trying to read an application setting
>
> Dim MyAppMgr as new System.configuration.AppsettingsReader
> Me.textbox1.text = MyAppMgr.Getvalue("MyServerName",string)
> Now when I execute the first line I get a system.dll exception because it
> says required attiubte 'Value' not found.
>
> What value, there are no choices possibles either as other objects or as
> parameters for AppsettingsReader in intellisense. If I don't include the
> word new in the line obviously MyappMgr object stays to nothing and the next
> line gives me an error.
>
> How do I get out of this friggin catch 22.
>
> Any help appreciated.
>
> Bob
>
>

It's telling you that it can't find "MyServerName"

Chris
Author
29 Jan 2006 12:17 AM
Bob
No the line that gives me an unhandled exception is the Dim Line.
Bob


Show quoteHide quote
"I Don't Like Spam" <no@spam.com> wrote in message
news:urFUuGGJGHA.3492@TK2MSFTNGP09.phx.gbl...
> Bob wrote:
>> Vs2003, Winform app, trying to read an application setting
>>
>> Dim MyAppMgr as new System.configuration.AppsettingsReader
>> Me.textbox1.text = MyAppMgr.Getvalue("MyServerName",string)
>> Now when I execute the first line I get a system.dll exception because it
>> says required attiubte 'Value' not found.
>>
>> What value, there are no choices possibles either as other objects or as
>> parameters for AppsettingsReader in intellisense. If I don't include the
>> word new in the line obviously MyappMgr object stays to nothing and the
>> next line gives me an error.
>>
>> How do I get out of this friggin catch 22.
>>
>> Any help appreciated.
>>
>> Bob
>>
>>
>
> It's telling you that it can't find "MyServerName"
>
> Chris
Author
29 Jan 2006 4:56 AM
Rocky
Dim MyAppMgr As New System.configuration.AppSettingsReader
Me.TextBox1.Text = MyAppMgr.GetValue("MyServerName",
GetType(String)).ToString

Show quoteHide quote
"Bob" <bduf***@sgiims.com> wrote in message
news:%23dNsclGJGHA.2012@TK2MSFTNGP14.phx.gbl...
> No the line that gives me an unhandled exception is the Dim Line.
> Bob
>
>
> "I Don't Like Spam" <no@spam.com> wrote in message
> news:urFUuGGJGHA.3492@TK2MSFTNGP09.phx.gbl...
>> Bob wrote:
>>> Vs2003, Winform app, trying to read an application setting
>>>
>>> Dim MyAppMgr as new System.configuration.AppsettingsReader
>>> Me.textbox1.text = MyAppMgr.Getvalue("MyServerName",string)
>>> Now when I execute the first line I get a system.dll exception because
>>> it says required attiubte 'Value' not found.
>>>
>>> What value, there are no choices possibles either as other objects or as
>>> parameters for AppsettingsReader in intellisense. If I don't include the
>>> word new in the line obviously MyappMgr object stays to nothing and the
>>> next line gives me an error.
>>>
>>> How do I get out of this friggin catch 22.
>>>
>>> Any help appreciated.
>>>
>>> Bob
>>>
>>>
>>
>> It's telling you that it can't find "MyServerName"
>>
>> Chris
>
>
Author
29 Jan 2006 11:50 AM
Ken Tucker [MVP]
Hi,

            This is how I do it.

http://www.vb-tips.com/default.aspx?ID=86c1810a-1e9d-4b9f-97e9-414986d2fb7d

Ken
-----------------
Show quoteHide quote
"Bob" <bduf***@sgiims.com> wrote in message
news:uG43XtFJGHA.1312@TK2MSFTNGP09.phx.gbl...
> Vs2003, Winform app, trying to read an application setting
>
> Dim MyAppMgr as new System.configuration.AppsettingsReader
> Me.textbox1.text = MyAppMgr.Getvalue("MyServerName",string)
> Now when I execute the first line I get a system.dll exception because it
> says required attiubte 'Value' not found.
>
> What value, there are no choices possibles either as other objects or as
> parameters for AppsettingsReader in intellisense. If I don't include the
> word new in the line obviously MyappMgr object stays to nothing and the
> next line gives me an error.
>
> How do I get out of this friggin catch 22.
>
> Any help appreciated.
>
> Bob
>
>
Author
29 Jan 2006 8:16 PM
Bob
Thank you all,
Bob
Show quoteHide quote
"Ken Tucker [MVP]" <vb***@bellsouth.net> wrote in message
news:OGntBpMJGHA.1180@TK2MSFTNGP09.phx.gbl...
> Hi,
>
>            This is how I do it.
>
> http://www.vb-tips.com/default.aspx?ID=86c1810a-1e9d-4b9f-97e9-414986d2fb7d
>
> Ken
> -----------------
> "Bob" <bduf***@sgiims.com> wrote in message
> news:uG43XtFJGHA.1312@TK2MSFTNGP09.phx.gbl...
>> Vs2003, Winform app, trying to read an application setting
>>
>> Dim MyAppMgr as new System.configuration.AppsettingsReader
>> Me.textbox1.text = MyAppMgr.Getvalue("MyServerName",string)
>> Now when I execute the first line I get a system.dll exception because it
>> says required attiubte 'Value' not found.
>>
>> What value, there are no choices possibles either as other objects or as
>> parameters for AppsettingsReader in intellisense. If I don't include the
>> word new in the line obviously MyappMgr object stays to nothing and the
>> next line gives me an error.
>>
>> How do I get out of this friggin catch 22.
>>
>> Any help appreciated.
>>
>> Bob
>>
>>
>
>