• 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
Problem with date and time columns both bound to the same date attribute
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Problem with date and time columns both bound to the same date attribute


  • Subject: Problem with date and time columns both bound to the same date attribute
  • From: Andrew Madsen <email@hidden>
  • Date: Sun, 23 Dec 2007 00:39:13 -0700

I've found something that I think is a bug (and will file with Apple) but in the meantime I'd like to know if anyone has a reasonable workaround. I've got a Core Data app and each entity has a date attribute. I have a table that shows the entities with a column for each attribute. I have a column for the date and another column for the time. These are both bound to the same date attribute. Each has a formatter that makes it so the date column displays the date and the time column displays the time. The problem is, if you edit an entity's date by double clicking on the date column then entering a new date, the time gets reset to 00:00 and the same thing happens if you edit the time (date gets reset to 1/1/1970 or whatever). I've posted a very simple example project here: http://www.andrewmadsen.com/misc/TimeAndDate.zip . This project was created by making an incredibly simple (one entity with one attribute) Core Data model, dragging it into IB to create an interface, then adding a second column and setting up formatters so one column shows date, the other time. I didn't write any code for it. If you add an entity, set a date for it, then set a time, you'll immediately see that the date reverts back to Jan 1 1970. This is exactly the problem I'm describing.

Anyway, I can't see why this behavior would be desired, so I think this is in fact a bug. Has anyone seen this before and come up with a reasonably elegant workaround?

Thanks,
Andrew
_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:
This email sent to email@hidden


  • Prev by Date: NSHTTPCookieStorage notification troubles
  • Next by Date: Re: NSTextField Size
  • Previous by thread: Re: NSHTTPCookieStorage notification troubles
  • Next by thread: Re: Problem with date and time columns both bound to the same date attribute
  • Index(es):
    • Date
    • Thread