I have a parent view controller and a child table view controller each embedded in a navigation view controller. It looks like so:
I want to make it so when I click the button Done, the Next button is enabled. I have tried to use [self.view setNeedsDisplay]
but no luck, tried other things such as setting vc.nextButton.isEnable = True
but nope. I've been working on this for a few hours with no avail. Please explain your solution as well.
Here is the whole thing
Asked
Active
Viewed 144 times
0

suntzu
- 65
- 3
- 13
-
How are you defining vc? – rdelmar Nov 26 '14 at 00:53
-
`ExampleViewController *vc = [[ExampleViewController alloc] init]` @rdelmar – suntzu Nov 26 '14 at 04:31
-
That's just creating a new instance, it's not the one you have on screen. If this code is in the child view controller, you can access the parent with self.parentViewController. You might need to use self.navigationController.parentViewController if the controller is embedded in a navigation controller. You should check the class of self.parentViewController to see what it is. – rdelmar Nov 26 '14 at 04:32
-
uploaded another image to show you what I have set up @rdelmar – suntzu Nov 26 '14 at 04:47
-
It's your app, so you need to figure out the relationships between your controllers, I'm not going to do it for you. Try throwing some logs in there, and see what they give you. – rdelmar Nov 26 '14 at 04:52