Invalid value of the string instance variables
Invalid value of the string instance variables
- Subject: Invalid value of the string instance variables
- From: Tan Dung Ho <email@hidden>
- Date: Mon, 31 Jan 2005 15:57:34 +0700
I implemented the AppController classs in my project. It had a
instance variable which declared NSString (NSString* strValue,..) and
the method to set value:
-(void)setStrValue: (NSString*)value
{
strValue = [NSString stringWithString:value];
}
The setStrValue's called by other object. This object has a instant
variable point to AppController.
In the AppController class, I wrote a method named "processString" to
process "strValue" variable. It is no problem when I call
processString method. But if this method was called in action method
(eg. (IBAction)buttonClicked:(id)sender), it cause a problem when
access value of strValue varable although it was set before.
I debug step-by-step my program and show all values of instant
variables during debuging. strValue's "invalid" value but its address
was valid.
Anybody tell me this problem?
Thank in advance.
Tan Dung
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden