FROM : Bill Coleman
DATE : Sun Aug 13 02:21:48 2006
On Aug 10, 2006, at 9:18 AM, Lee Gillen wrote:
> I have a Core Data application that has a date attribute for one of
> the entities. I'd like to set the default value for this attribute to
> be the current date and time that the data was created. I found that I
> can use a default value of 'now' or 'today' and it will populate the
> attribute with the date the data was created, but not the time.
I couldn't do this with a default value -- ran into the same problem,
"TODAY" produces a time of 12 noon.
What I did was set the time to [NSDate date] in code after creating
the object.
Bill Coleman, AA4LR, PP-ASEL Mail: <email_removed>
Quote: "We invented personal computing."
-- Bill Gates @ TechNet / MSDN 2003
DATE : Sun Aug 13 02:21:48 2006
On Aug 10, 2006, at 9:18 AM, Lee Gillen wrote:
> I have a Core Data application that has a date attribute for one of
> the entities. I'd like to set the default value for this attribute to
> be the current date and time that the data was created. I found that I
> can use a default value of 'now' or 'today' and it will populate the
> attribute with the date the data was created, but not the time.
I couldn't do this with a default value -- ran into the same problem,
"TODAY" produces a time of 12 noon.
What I did was set the time to [NSDate date] in code after creating
the object.
Bill Coleman, AA4LR, PP-ASEL Mail: <email_removed>
Quote: "We invented personal computing."
-- Bill Gates @ TechNet / MSDN 2003
| Related mails | Author | Date |
|---|---|---|
| Lee Gillen | Aug 10, 15:18 | |
| Robert Cerny | Aug 10, 15:56 | |
| Bill Coleman | Aug 13, 02:21 | |
| Lee Gillen | Aug 13, 20:14 |






Cocoa mail archive

