Quote:
Originally Posted by prudhvi
Hi Deejay,can you send your code..
|
During application startup, I'm setting town name as:
Code:
MySingleton *sharedInstance = [MySingleton sharedInstance];
sharedInstance.townName = @"New York";
On all tabs, I'm using the same singleton instance to show town name:
Code:
[townName setText:sharedInstance.townName];
Singleton is 100% ok, (made "by the book") since I'm using this townName in all 5 tabs and all of them shows the townName set during application startup.
But if I change townName, and save it:
Code:
MySingleton *sharedInstance = [MySingleton sharedInstance];
sharedInstance.townName = @"Chicago";
and change a view by selecting any of the tabs, the old value is still shown.
I need to refresh data, to have a new town name on all tabs after save.