year and month wrong

  • Thread starter Thread starter Keith
  • Start date Start date
K

Keith

I have been away from Access for a while so I might be doing something stupid.

I an writing a report and in the header I want to show the month and year
taken from a date field. I have used the control source as

=month([Date Entered])
=year([Date Entered])

But the always come out as January and 1905

What am I doing wrong?
 
What is the format of the text boxes? I would just set the control source to
the actual date and then use the format to set the format (month, year,...)

Your problem might be that the following is returning a number from 1-12.
=month([Date Entered])
If you then set the format property of the control, you are formatting the
small number, not a date.
 
Back
Top