showing only date not time

M

MS Novice

I've added a field on my form that automaticly fills in the date. But it
also shows the time. I put now() in the Default value. Is there a way where
I can ONLY show the date and NOT the time?

Thanks
 
A

Allen Browne

Set the Default Value to:
=Date()

To fix the existing records, run an Update query and use DateValue() to lose
the time component.
 
M

MS Novice

Thanks to you both. It's these little minor things that can really drive you
crazy. Well at least I was close.
 
R

Rick Brandt

MS said:
Thanks to you both. It's these little minor things that can really
drive you crazy. Well at least I was close.

Just to give you a fuller picture here...

Access DateTimes ALWAYS contain a Year, Month, Day, Hour, Minute, and
Second. When we informally describe an Access DateTime "Containing only the
time" what we really are talking about are times of day that occured on
12/30/1899. Similarly, when we describe a DateTime that "Contains only the
Date" what we really are describing is a Date having a time of exactly
midnight.

It is just that Access chooses to suppress the display of the date
12/30/1899 and the time of midnight unless you explicitly force it to.

Being aware of this makes some of the DateTime behaviors that you will
encounter easier to understand.
 
Top