iphone - Objective-C Novice. Change property in Controller from another Controller? -


so, first of i'm new posting in here. have been browsing stackoverflow ages , first time i'm asking question.

the context: have 3 views. 1 introductory view, upload view , main view. classes (with respective headers) have rootviewcontroller (switchviewcontroller), introviewcontroller , uploadviewcontroller. first view shown introview. user presses button (declared in switchviewcontroller) takes them uploadview, in uploadview choose image , press button again go introview.

the thing while user gets pick image uiimagepickercontroller button switch views won't hide nor uiimageview have logo on top of view(screen). uiimageview , uibutton both declared in switchviewcontroller's header.

the code used:

uploadviewcontroller.h

#import [...] //imports @class switchviewcontroller; @interface uploadviewcontroller :  uiviewcontroller <uiimagepickercontrollerdelegate,  uinavigationcontrollerdelegate,uiactionsheetdelegate> {     uitextfield *imagetextfield;     uiimageview *uploadedimage;     switchviewcontroller *switchviewcontroller; [...] }  @property (nonatomic, retain) switchviewcontroller *switchviewcontroller; @property (nonatomic, retain) iboutlet uitextfield *imagetextfield; @property (nonatomic, retain) iboutlet uiimageview *uploadedimage; [...] @end 

uploadviewcontroller.m

[...] - (ibaction) selectimagebuttonpressed { self.switchviewcontroller.submitbutton.hidden = yes; self.switchviewcontroller.imagelogo.hidden = yes;  [...] //continues 

i begun programming in objective-c please forgive me if question essential. have looked , following "beginning iphone 3 development" of apress. if helps understand basics lost.

i thank help!!

ps: if clearer answer question switchviewcontroller.h , .m snippet codes can provided if asked. thought text big is.

@joze think may have understood problem switchviewcontroller variable of class uploadviewcontroller if variable wont affect switchviewcontroller view. when calling switchviewcontroller view @ time have initwithnibname: bundle: , hide button , imageview , need switchviewcontroller.delegate = self; , call view modally or ever way want it.

ps. m not sure spelling correct. dont have xcode @ home. hope problem solves this.


Comments

Popular posts from this blog

java - SNMP4J General Variable Binding Error -

windows - Python Service Installation - "Could not find PythonClass entry" -

Determine if a XmlNode is empty or null in C#? -