Do something when application terminated

by nik 2. March 2009 04:46

//in mainAppDelegate.m

 - (void)applicationDidFinishLaunching:(UIApplication *)application {

//

//init code

//

  atexit(applicationWillTerminate);

 

void applicationWillTerminate(){

//some stuff

 

 

//in mainAppDelegate.h

@interface mainAppDelegate : NSObject <UIApplicationDelegate> {

//.....

}

void applicationWillTerminate(); 

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags: , ,

General

Powered by BlogEngine.NET 1.4.5.0
Theme by Mads Kristensen