I’m making an application from a TabBarController (storyboard template). The tabs are all UINavigationControllers with UITableViews. Each time Tab 2 is entered the tableview should update (look for new items to add), but it only loads once! (First time tab is entered.) How to do this?
A closer description of my issue:
When I’m in Tab 1, I select some cells (objects) to add to the TableView in Tab 2. Cell tap is changing a boolean for the reprecented object in a plist of objects.
So if I select objects in Tab 1 at launch, and then enter Tab 2, this TableView is filled with the cells because it’s the first time I enter Tab 2 and it loads.
But if I go back to Tab 1 and select some more objects, these objects are not displayed in Tab 2 because the TableView is already loaded. So how to reload the Tab 2 TableView? Should I do this when the selection of tab 2 is happening? I have no class or reference for TabBarController, it’s in storyboard only. Or maybe should I do it in the addObject action in Tab 1? Thank you for answer.
Maybe you can try add
in the
viewWillAppearof Tab 2 view controller.