Display age instead of date of birth

Date type fields are often used in forms to request a date of birth or a date of employment. You may wish to sort information by age rather than by date. It is possible to have this information without having to calculate the date manually.

Field configuration

In your Date Type field, check the box for Show as age. This will add the Display options field, allowing you to display the information as a date, age or both.

 

date-field-settings.png

How it works in edit mode

When a form is filled out or edited, the display mode selected will not affect the field: a date will always be requested.

member-add.png

How it works in view mode and in reports

In view mode as well as in exports, the display will be done according to the choice made in the "Display options": 

  • Date only: the date, in the format indicated in the field. example: 16-03-1991
  • Age only: the age, in years. example: 30 years
  • Date + age : the date, followed by the age. example : 16-03-1991 (30 years)

member-view.png

 

Go further

Forms management

Associating forms to different contexts

 

 

 

Was this article useful?

0 out of 0 found this helpful

Comments

0 comments

Please sign in to leave a comment.