Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > problem with getter and setter not working

Reply
Thread Tools

problem with getter and setter not working

 
 
Jimi200478
Guest
Posts: n/a
 
      05-26-2006
you're almost there. you just need to change the code a little bit:

change the code in the get to:
*notice that the viewstate key is a string

_MyName = Me.ViewState("MyName").ToString
Return _MyName

change the code in the set to:
*notice that the viewstate key is a string

_MyName = value
Me.ViewState("MyName") = _MyName

 
Reply With Quote
 
 
 
 
Adam Sandler
Guest
Posts: n/a
 
      05-26-2006
That was it... Thanks gents for the help!!!!

 
Reply With Quote
 
 
 
 
Jimi200478
Guest
Posts: n/a
 
      05-26-2006
you're very welcome. Happy Programming.

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
getter and setter and list appends dasacc22 Python 6 04-24-2009 11:39 PM
C# webservices proxy generates public member variables and no getter/setter methods?? Steve ASP .Net Web Services 1 03-24-2006 02:50 AM
Static fields accessed by getter/setter...what happens? Stacey Java 1 02-10-2004 02:28 PM
Tired of 100s of stupid Getter/Setter methods Timo Nentwig Java 75 01-18-2004 05:17 AM
May I do data type conversion within getter/setter? Raoul Markus Java 3 09-20-2003 06:30 PM



Advertisments