views:

22

answers:

1

This is for iOS4 with multitask issue. How do I reload view after my app is re-appear from background running app?

A: 

You want your view controller to listen for UIApplicationWillEnterForegroundNotification:

Posted shortly before an application leaves the background state on its way to becoming the active application.

Also mentioned in the iOS Application Programming Guide:

The UIApplicationWillEnterForegroundNotification notification is also available for tracking when your application reenters the foreground. Objects in your application can use the default notification center to register for this notification.

In your handler for this notification, you can trigger whatever refreshing/redrawing you need.

You can read more about Notifications in the Cocoa Core Competencies document.

Shaggy Frog
That's what I'm looking for. Thanks so much!
Quy