PC Review


Reply
Thread Tools Rate Thread

age calculator to display months as well as years

 
 
Karen
Guest
Posts: n/a
 
      20th Jul 2004
I want Access (97) to calculate somebody's age. I know you
can do that by setting the Control Source property of a
textbox to

=DateDiff("yyyy",[Date],Date())+(Format([Date],"mmdd")
>Format(Date(),"mmdd"))


but that will "just" display the person's age in years
whereas I'm looking for months as well.

Anybody has an idea how to do this without including a
macro?

Karen

 
Reply With Quote
 
 
 
 
Rick B
Guest
Posts: n/a
 
      20th Jul 2004
Do a search. This was answered within the last three weeks or so. I
remember seeing it posted.

Rick B


"Karen" <(E-Mail Removed)> wrote in message
news:090e01c46e6d$c69d8880$(E-Mail Removed)...
I want Access (97) to calculate somebody's age. I know you
can do that by setting the Control Source property of a
textbox to

=DateDiff("yyyy",[Date],Date())+(Format([Date],"mmdd")
>Format(Date(),"mmdd"))


but that will "just" display the person's age in years
whereas I'm looking for months as well.

Anybody has an idea how to do this without including a
macro?

Karen


 
Reply With Quote
 
 
 
 
fredg
Guest
Posts: n/a
 
      20th Jul 2004
On Tue, 20 Jul 2004 08:25:23 -0700, Karen wrote:

> I want Access (97) to calculate somebody's age. I know you
> can do that by setting the Control Source property of a
> textbox to
>
> =DateDiff("yyyy",[Date],Date())+(Format([Date],"mmdd")
>>Format(Date(),"mmdd"))

>
> but that will "just" display the person's age in years
> whereas I'm looking for months as well.
>
> Anybody has an idea how to do this without including a
> macro?
>
> Karen


You'll need code!

See Doug Steele's code at:
http://members.rogers.com/douglas.j....iff2Dates.html

--
Fred
Please only reply to this newsgroup.
I do not reply to personal email.
 
Reply With Quote
 
Graham R Seach
Guest
Posts: n/a
 
      21st Jul 2004
In addition to the fine code on Doug's site, there's also this:
http://www.pacificdb.com.au/MVP/Code/Age2.htm

Regards,
Graham R Seach
Microsoft Access MVP
Sydney, Australia

Microsoft Access 2003 VBA Programmer's Reference
http://www.wiley.com/WileyCDA/WileyT...764559036.html


"fredg" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> On Tue, 20 Jul 2004 08:25:23 -0700, Karen wrote:
>
> > I want Access (97) to calculate somebody's age. I know you
> > can do that by setting the Control Source property of a
> > textbox to
> >
> > =DateDiff("yyyy",[Date],Date())+(Format([Date],"mmdd")
> >>Format(Date(),"mmdd"))

> >
> > but that will "just" display the person's age in years
> > whereas I'm looking for months as well.
> >
> > Anybody has an idea how to do this without including a
> > macro?
> >
> > Karen

>
> You'll need code!
>
> See Doug Steele's code at:
> http://members.rogers.com/douglas.j....iff2Dates.html
>
> --
> Fred
> Please only reply to this newsgroup.
> I do not reply to personal email.



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
well well well, it's a small world indeed ... muckshifter General Discussion 9 15th Jun 2009 09:30 AM
Re: Well, well, well, guess chroot isn't so great after all roy.shysterwitz@gmail.com Windows Vista General Discussion 1 1st Oct 2007 10:53 AM
well well well, seems that "vista" has some dvd driver problems EMERY_BILL@HOTMAIL.COM Windows Vista Hardware 0 29th Jul 2007 04:46 AM
Convert Years to Years/Months/Days coreymartin@gmail.com Microsoft Excel Discussion 4 4th Jan 2006 03:58 PM
Display a person's age in years & months: for example 4;11 =?Utf-8?B?U2hhdW5fVlQ=?= Microsoft Excel Misc 3 23rd Sep 2004 07:19 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 08:13 PM.