• 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: table column with <date value> null placeholder
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: table column with <date value> null placeholder


  • Subject: Re: table column with <date value> null placeholder
  • From: Eric Friedman <email@hidden>
  • Date: Fri, 6 May 2005 17:06:51 -0700

I found the answer on mmalc's bindings site (sorry, should have known
it'd be there):  a programmatically set binding can take an NSString
place holder just fine, so no need to hack the data or write a custom
NSValueTransformer (though I suppose that's a legitimate approach as
well).

Sean, I'm interested in your comment about date format as a user
preference.  Of course Interface Builder's formatter wants me to
choose exactly one format string.  I suppose what you say could be
done through user preferences, but I'm curious -- do a lot of folks go
to this trouble?  Speaking only for myself, I can honestly say that
I've never given it a second thought in apps that I use....



On 5/6/05, Sean McBride <email@hidden> wrote:
> On 2005-05-06 06:30, Eric Friedman said:
>
> >I have an NSTableColumn with a formatter that restricts input to date
> >values of the form mm/yyyy.
> >
> >I'd like to display a greyed out placeholder in cells with nil values:
> >text should be "mm/yyyy" so that users know what format to use when
> >entering the date value.
> >
> >When I select the column in IB and view its bindings inspector,
> >however, the Null Placeholder binding under value insists on getting a
> ><date value> -- it doesn't seem possible to put in "mm/yyyy" instead
> >of an actual date.  I'd rather not use a bogus date, because I think
> >that's confusing/misleading.
>
> Maybe you should use real NSCalendarDate's with dummy values for 'day'
> and then use a value transformer to create a string of the date as 'yyyy/
> mm'. Or perhaps instead of your model being a date, it should just be a
> string.
>
> I also I encourage you to display dates according to the user's
> preferences; that is: 'yyyy-mm' vs 'mm-yyyy'.
>
> --
> ____________________________________________________________
> Sean McBride, B. Eng                 email@hidden
> Rogue Research                        www.rogue-research.com
> Mac Software Developer              Montréal, Québec, Canada
>
>
 _______________________________________________
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

  • Follow-Ups:
    • Re: table column with <date value> null placeholder
      • From: "Sean McBride" <email@hidden>
References: 
 >table column with <date value> null placeholder (From: Eric Friedman <email@hidden>)
 >Re: table column with <date value> null placeholder (From: "Sean McBride" <email@hidden>)

  • Prev by Date: Re: Function to write to one pixel?
  • Next by Date: problems with sheets
  • Previous by thread: Re: table column with <date value> null placeholder
  • Next by thread: Re: table column with <date value> null placeholder
  • Index(es):
    • Date
    • Thread