Format Date Field with Month/Year only

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

What do I need to do to allow my date/time field to take Month and Date only? For example 04/04 for April 200

I try input masks of m/yy amd mm/yy and then I can't type in the field or modify the fields on a form. It works if I enter a full date such as 04/01/04 but I would like to avoid having to enter extra numbers

Help please!
 
Check Access Help carefully the differences between InputMask Property and
the Format Property. I think you got them mixed up.

OTOH, date(/time) values in Access must be *full* date(/time), i.e.
day/month/year since a date/time value is stored similar to a double where
the integral represents the number of days sine 30/Dec/1899 and the
franctional part represents the time since mid-night.

Thus, you cannot store only month and year only in a date/time Field. If
you don't use day, default it to 01.

HTH
Van T. Dinh
MVP (Access)



bdehning said:
What do I need to do to allow my date/time field to take Month and Date
only? For example 04/04 for April 2004
I try input masks of m/yy amd mm/yy and then I can't type in the field or
modify the fields on a form. It works if I enter a full date such as
04/01/04 but I would like to avoid having to enter extra numbers.
 
What do I need to do to allow my date/time field to take Month and Date only? For example 04/04 for April 2004

I try input masks of m/yy amd mm/yy and then I can't type in the field or modify the fields on a form. It works if I enter a full date such as 04/01/04 but I would like to avoid having to enter extra numbers.

Help please!

I'd use a Text field instead. A Date/Time field is stored as a double
float number, a count of days and fractions of a day since midnight,
December 30, 1899 - as such it corresponds to a precise instant of
time. A whole month isn't an instant!

Use a Text field with an Input Mask of 00/00.
 
Back
Top