Only the UIViewController pushed gets messages like viewWillAppear. The only way I've found is to fake it by calling the UITableController's viewWillAppear from inside the UIViewController's method.
Only the UIViewController pushed gets messages like viewWillAppear. The only way I've found is to fake it by calling the UITableController's viewWillAppear from inside the UIViewController's method.
Ok so it is working correctly then it seems you cannot have a UIViewController that contains a UITableController in a simple manner. I have it all wired up correctly but the table wont load any data since it isn't receiving some of the necessary messages then. I can make that viewWillAppear call but it seems its too late or something else is going on cause that alone does not fix this. The data is still not loaded.
I have an enumeration call inside the tablecontroller's viewWillAppear but it wont run it when it isn't the one receiving the messages
It really shouldn't be that hard. You might want to post your enumeration code, because there's no reason I can see why the UITableViewController should behave any differently if it's viewWilAppear is called by the parent UIViewController's viewWillAppear.
Also, how are you loading the UITableView itself into the parent UITableViewController? If you did this too late, it could also cause the problem you are describing. I would expect you should do it in the parent UIViewController's viewDidLoad at the latest.
It really shouldn't be that hard. You might want to post your enumeration code, because there's no reason I can see why the UITableViewController should behave any differently if it's viewWilAppear is called by the parent UIViewController's viewWillAppear.
Also, how are you loading the UITableView itself into the parent UITableViewController? If you did this too late, it could also cause the problem you are describing. I would expect you should do it in the parent UIViewController's viewDidLoad at the latest.
The enumeration code works when I only push the tableviewcontroller and not its parent which is odd and the table shows up when I do this.
I haven't added anything specifically to the code to load the UITableView (I'm using the WWDC10 sample for the MyImagePicker). The view has its own xib that assigns the view of the controller to the table object in the layout.
Yes, none of the view...Appear functions will be called unless you call them from the UIViewController being pushed. I believe it's the same with the viewWillDisappear in case you are using it too.
Yes, none of the view...Appear functions will be called unless you call them from the UIViewController being pushed. I believe it's the same with the viewWillDisappear in case you are using it too.
Still not working... I have the delegate and dataSource on the TableView set to the TableViewController in the xib for the viewcontroller.
Sorry, without more code posted, I have no idea what you are doing wrong. If you can't share more information, there's really no way I can see to help.
Sorry, without more code posted, I have no idea what you are doing wrong. If you can't share more information, there's really no way I can see to help.
Ok I fixed it using this sample to integrate and change my implementation for now. It should be possible however to modularize the view the way I'm intending to. So, if you do get a chance to take a look at the code I would still be interested to see what I was doing wrong. Thanks.
Sorry I'm only now getting to look at this, I was slammed over the weekend.
The only way I know how to do what you want is to manually add the view of the UITableViewController as a subview to the UIViewController you want it to be inside of. I don't think IB can do that step for you.
Unfortunately, I have no idea how to get your app to run in the simulator, and I don't have a iOS4 device, so I could not test it. Personally, I think you are better off following the link you posted.