i have problems with a really basic thing. setting properties after instantiation a UIViewController-
header.h
IBOutlet UITextField *actionLocationFld;
@property (nonatomic, retain) IBOutlet UITextField *actionLocationFld;
main.h
@synthesize actionLocationFld;
(void)loadSocialActionView:(id)sender
{
self.socialActionView = [[SocialActionViewController alloc] init];
self.socialActionView.actionLocationFld.text = @"test";
[self.view addSubview:self.socialActionView.view];
}
actionLocationFld is a UITextfield. i try to set the text value after instantiation but it does not work. it looks so easy but i can´t figure out. what do i wrong?
any suggestions?
i´ve solved it not by adding another property and passing it the value. it seems it is not possible to access the text property of an UITextfield by the way i tried. here´s the new code line
inside of my viewcontroller i pass the value forward to self.view.actionLocationFld.text