Patient DOB by Age

Hi Everyone,
I want to create a new text filed titled “Age” in new patient registration form beside DOB field. When user put age in years in this field system automatically filled DOB.
Please guide me step by step. I would be really appreciate in this regards.

Thanks,
M Sheeraz Shaikh.

You want system to randomly assign a date amongst 364 or so days based on age in years?

No. Actually I want to create a new text field beside DOB field in new patient registration form. We want both options either user input DOB or Age in number like 30, 35, 40 etc.
We don’t want to save “Age” in database just input “Age” for generating DOB in runtime. When user input “Age” then system automatically generate DOB and put in DOB field at runtime. By this mechanism system achieve the DOB year and Month and Day achieve from current system date. After that user can update Month and Day any time if he wants.

I hope you can understand my requirements,
I really very thankful to you in advance.
Regards,

This would require a new data type in our layout engine. Could be done and mainly this is done in the script library/options.inc.php if you want to take a look see…

I request you to please guide me step by step. I am not well familiar in Openemr technically. I really very thankful to you in advance.

Dear,
Please guide. I would be really thankful to you.

Regards,
M Sheeraz Shaikh.

Your requirement is very unusual for general use. To make this change you will need to find help someone familiar with PHP programming.

Do you want this change for benefit of data entry users not able to calculate the year mentally? Since they are able to type dates in DoB field, perhaps putting a sheet of paper with age and year handy will serve the same purpose. After saving the patient data, the users will be able to validate the number as the system shows age in years.

Best.