Try call [myPicker reloadAllComponents]; in viewWillAppear (for that you should make subclass of UIViewController).
How to reload an object connected in xib
-
14-04-2022 - |
Question
I have a UIViewController
(myViewController) with a XIB file. In this XIB file, I have connected an other object UIPickerViewController
(myPicker).
When my UIViewController
is allocated, initialized and pushed as a viewcontroller, the UIPIckerViewController
displays its instance as it should.
The user can modaly open a settingscontroller from myViewController
to adjust some settings.
When the settingscontroller is dismissed, myViewController is updated (buttons, text, tableview, etc).
However, myPicker is not Only when the UIViewController
is initalized and pushed again, myPicker is updated.
Is there any good ways to reload myPicker in myViewController without initializing UIViewController
again?
Solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow