• 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: Setting contents of NSTextField to NSCalendarDate
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Setting contents of NSTextField to NSCalendarDate


  • Subject: Re: Setting contents of NSTextField to NSCalendarDate
  • From: Chris Hanson <email@hidden>
  • Date: Fri, 28 Nov 2003 20:22:51 -0600

On Nov 27, 2003, at 2:32 PM, Frank wrote:
I setup a date formatter, but there seems to be no function to set the value, like

[dateField setCalendarDateValue: someNSCalendarDate]

Use -[NSControl setObjectValue:]; this will run the object through the control's cell's formatter to generate the string to display.

This is a pattern you can use in Cocoa to display any type of object. You just need to create an appropriate formatter class.

-- Chris

--
Chris Hanson <email@hidden>
bDistributed.com, Inc.
Outsourcing Vendor Evaluation
Custom Mac OS X Development
Cocoa Developer Training
_______________________________________________
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.

References: 
 >Setting contents of NSTextField to NSCalendarDate (From: Frank <email@hidden>)

  • Prev by Date: Re: Query regarding DateFormat
  • Next by Date: Re: Catching JNI exception in Objective C
  • Previous by thread: Re: Setting contents of NSTextField to NSCalendarDate
  • Next by thread: const char* to char*
  • Index(es):
    • Date
    • Thread