On 21 Jun 08, at 21:59, Adam Thorsen wrote:
I'm attempting to store an unsigned long long (stored in memory in an NSNumber) in user defaults, but it appears to be truncated upon retrieval. This may have something to do with the fact that I'm using the setInteger method of NSUserDefaults to write the unsigned long long value.

It probably does! On most 32-bit systems, long longs are 64 bits wide, while integers are 32 bits.

However, there appears to be no other way to set an integer in user defaults. Is there another technique I can use within the Cocoa API?

How about [[NSUserDefaults standardUserDefaults] setObject:myNSNumber forKey:key] ?
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to