no

How to detect first time app launch on iPhone in Xcode

Inside the "AppDelegate.m", change - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary ...

Inside the "AppDelegate.m", change

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
    // Override point for customization after application launch.
    return YES;
}

to

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
    if ([[NSUserDefaults standardUserDefaults] boolForKey:@"HasLaunchedOnce"])
    {
        // app already launched
    }
    else
    {
        [[NSUserDefaults standardUserDefaults] setBool:YES forKey:@"HasLaunchedOnce"];
        [[NSUserDefaults standardUserDefaults] synchronize];
        // This is the first launch ever
    }
}

Related

xcode 792451531097796821

Post a Comment Default Comments

item