Re: if ([[NSUserDefaults preferences] check box]==true) ?
Re: if ([[NSUserDefaults preferences] check box]==true) ?
- Subject: Re: if ([[NSUserDefaults preferences] check box]==true) ?
- From: mmalcolm crawford <email@hidden>
- Date: Sun, 9 Nov 2003 17:51:31 -0800
On Nov 9, 2003, at 5:33 PM, Scott Anguish wrote:
true.. however,if you want your defaults even more readable, you
should also support getting a string back, either Yes, YES, yeS, YeS,
etc... :-)
This is one of the attractions of using boolForKey:
- (BOOL)boolForKey:(NSString *)defaultName
Invokes stringForKey: with key defaultName. Returns YES if the value
associated with defaultName is an NSString containing the word yes in
uppercase or lowercase or responds to the intValue message by returning
a nonzero value. Otherwise, returns NO.
mmalc
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.