• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: How to get date string formats in System International Preferences
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to get date string formats in System International Preferences


  • Subject: Re: How to get date string formats in System International Preferences
  • From: "Louis C. Sacha" <email@hidden>
  • Date: Tue, 25 May 2004 20:14:53 -0700

Hello...

In the documentation for NSUserDefaults, the "Constants" section has a number of keys that can be used to get some of the global user preferences.

http://developer.apple.com/documentation/Cocoa/Reference/Foundation/ObjC_classic/Classes/NSUserDefaults.html

Some of the relevant ones would be "NSDateFormatString", "NSShortDateFormatString", "NSTimeDateFormatString", and "NSTimeFormatString".

Hope that helps,

Louis


Hi

on 04.5.26 0:59 AM, Lorenzo at email@hidden wrote:
you should get the current date/time this way:
NSCalendarDate *nowDateTime = [NSCalendarDate calendarDate];

then you can transform "nowDateTime" to a simple NSString this way:
NSString *fullDateTimeString = [nowDateTime description];

Does anybody know how to get the date string formats that are defined in
System International Preferences?

Satoshi
_______________________________________________
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.


  • Follow-Ups:
    • Re: How to get date string formats in System International Preferences
      • From: Satoshi Matsumoto <email@hidden>
References: 
 >How to get date string formats in System International Preferences (From: Satoshi Matsumoto <email@hidden>)

  • Prev by Date: Re: How to get date string formats in System International Preferences
  • Next by Date: Cocoa Rules
  • Previous by thread: Re: How to get date string formats in System International Preferences
  • Next by thread: Re: How to get date string formats in System International Preferences
  • Index(es):
    • Date
    • Thread