Thread: Date query
View Single Post
  #2  
Old June 2nd, 2010, 09:49 PM posted to microsoft.public.access.forms
Jeff Boyce
external usenet poster
 
Posts: 8,621
Default Date query

Jeff

You mentioned subtracting the input age from 1901, but then you mention the age field holding only hours, days, weeks or months.

How are you doing that subtraction if the person is over 1 year old?

And it sounds like you are trying to calculate the year born ... if the person is under one year old, weren't they born in 1900? Could you just check the "age field" to see if there's a letter, then decide they were less than one?

More info, please...

Regards

Jeff Boyce
Microsoft Access MVP

--
Disclaimer: This author may have received products and services mentioned
in this post. Mention and/or description of a product or service herein
does not constitute endorsement thereof.

Any code or pseudocode included in this post is offered "as is", with no
guarantee as to suitability.

You can thank the FTC of the USA for making this disclaimer
possible/necessary.

"SeeAll" wrote in message ...
Hi,

I am using a census database to enter data from the 1901 UK census. To calculate the year born the input age is subtracted from 1901. However, when a child under one year old is enter, obviously an error shows.

What do I need to do to show 1901 when a child's age under one year is entered. The age field can hold three numbers and one letter (h = hours, d=days, w=weeks, m=months) if needed, eg., 5, 100, 5w.

Regards

Jeff