Re: Determining if it is the first time the application has launched?
Re: Determining if it is the first time the application has launched?
- Subject: Re: Determining if it is the first time the application has launched?
- From: daniel <email@hidden>
- Date: Mon, 17 Jan 2005 22:27:46 -0800
You probably want to set the preference as a BOOL, since you're reading it as one:
[preferences setBool:YES forKey:@"hasPreviouslyRun];
It so happens that the NSString @"yes" interpreted as a bool probably doesn't == 0, but you might as well be sure about it.
Daniel
On Jan 17, 2005, at 1:09 PM, James Andrews wrote:
if([preferences boolForKey:@"hasPreviouslyRun"]==false){
// Allow
hasPreviouslyRun=true;
// sets it in the NSUserDefaults
[preferences setObject:@"yes" forKey:@"hasPreviouslyRun"];
}
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden