Re: NSDatePicker / NSDatePickerCell
Re: NSDatePicker / NSDatePickerCell
- Subject: Re: NSDatePicker / NSDatePickerCell
- From: Troy Stephens <email@hidden>
- Date: Thu, 15 Sep 2005 13:31:08 -0700
See NSCalendar.h. Given an NSCalendar instance that you've
configured with the appropriate Locale and TimeZone, you can use the
following methods to convert between an NSDate and corresponding
NSDateComponents:
- (NSDate *)dateFromComponents:(NSDateComponents *)comps;
- (NSDateComponents *)components:(NSUInt)unitFlags fromDate:(NSDate *)
date;
With the date in component form, you can read and modify its era as
desired:
- (NSInt)era;
- (void)setEra:(NSInt)v;
On Sep 15, 2005, at 1:03 PM, SA Dev wrote:
Thanks, Troy:
Is there a way to use NSDatePicker with another control (like an
NSMatrix) to specify BC/AD easily? I guess the question is actually
"how can I easily 'toggle' a date between BC/AD" ...
- SADev
On Sep 15, 2005, at 3:53 PM, Troy Stephens wrote:
Is this flag actually implemented in 10.4 or are the docs wrong?
Sorry for the confusion. There's a mention of this in the Tiger
AppKit Release Notes:
"NSTimeZoneDatePickerElementFlag and NSEraDatePickerElementFlag
have been declared for possible future use, and do not yet have
any effect."
--
Troy Stephens
Cocoa Frameworks
Apple Computer, Inc.
_______________________________________________
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