How to detect first time app launch on an iPhone
问题 How can I detect the very first time launch of - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { // if very first launch than perform actionA // else perform actionB } method? 回答1: - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { if (![[NSUserDefaults standardUserDefaults] boolForKey:@"HasLaunchedOnce"]) { [[NSUserDefaults standardUserDefaults] setBool:YES forKey:@