I have a UITableViewController with static cells, created in a storyboard (Xcode 4).
For each cell, I assigned a TableViewCellController in order to have custom pickers (http://www.wannabegeek.com/?p=104, and an example of use here: http://timroadley.com/2012/02/26/core-data-basics-part-6-core-data-uipickerview/).
In my UITableViewController I create a new object, and I would like the TableViewCellController to have access to it.
The UITableViewController is set as delegate of the TableViewCellController, but in the init method (custom initializeInputView, called from initWithCoder) of the TableViewCellController, the delegate isn’t defined yet, so I can’t access the object by using self.delegate.
What’s the best way to pass that value from the UITableViewController to the TableViewCellController, or to access it from the TableViewCellController, upon initialization ?
Thanks
So here’s the way I did it. I used willDisplayCell in my parent UITableView, and cast the type of the static cell controller in order to access it’s dateValue property and initialize it.