Avatar of K Tin
K Tin
Flag for United States of America asked on

Calculate age in Microsoft Word

I am wanting to calculate age on a form document in word. I just need a easy to follow macro (I'm a newb to this).
Microsoft OfficeVB ScriptMicrosoft WordVBA

Avatar of undefined
Last Comment
Shums Faruk

8/22/2022 - Mon
Shums Faruk

I am not sure which form field you have, you'll need to do the work yourself. To help you get started, check below link:
How Can I Put Calculated Dates in Word?

Take a look and let me know what additional questions you have.
ASKER CERTIFIED SOLUTION
Shums Faruk

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question
K Tin

ASKER
Sorry I'm dense... so do I click Ctrl-F9 and name, within the brackets, {CalcAge} or {MACROBUTTON CalcAge}
Shums Faruk

If you already have Data Field as above then you just run Macro CalcAge
All of life is about relationships, and EE has made a viirtual community a real community. It lifts everyone's boat
William Peck
K Tin

ASKER
When I try to run the Macro I get an error "Run time error 5941 the requested member of the collection does not exist"
Shums Faruk

Please upload your sample document.
K Tin

ASKER
Uploaded
test.docm
Get an unlimited membership to EE for less than $4 a week.
Unlimited question asking, solutions, articles and more.
Shums Faruk

There is problem in your template. Let me make new one. Give me some time
SOLUTION
Log in to continue reading
Log In
Sign up - Free for 7 days
Get an unlimited membership to EE for less than $4 a week.
Unlimited question asking, solutions, articles and more.
Shums Faruk

Kindly note you need to double click on DOB Field and change the date in Default Date then run macro