Sorry if this seems like a simple question, but every time I search on google for this subject all I can find is how to pass data from a child view to a parent view, not vice versa.
Basically, I am presenting a modal view, which is in its own UINavigation controller. The modal view needs to know if it is allowed to be ‘edited’ by the user or not – so I thought the most simple way to do this would be to set a BOOL on the child view (isEdit) to TRUE (this would get set depending on the segue that is occurring) However because this modal view is being presented from a UINavigation controller – I cannot access it from the -(void)prepareForSegue function and set the BOOL directly. I have tried subclassing the UINav controller, and including a BOOL in it that can be set, then checked back in the child view, but I cannot seem to access the controller from the child view – I would include my code, but I am sure there must be a more simple way of accomplishing this task!
Is anyone able to suggest a more economical way of passing this boolean ‘through’ the UINavigationController to the child view?
Thanks
If your segue invokes a navigation controller, you can set properties on the root view controller from
-prepareForSegue, like so