Age calculation

Hey there,

I'm creating an XLSForm to be used on ODK application and I want the user
to enter their date of birth and then to have an equation to calculate the
age- is that possible?

Thanks,
Mai

1 Like

Hi Mai,
I Have an idea and i want to share it with you.

  1. the field of the date of birth must be a required field, its
    appearence must be "year" . in this example, i ask for the year of birth
    not the full date of birth.
  2. a calculated field AGE: calculation=2014-${Datebirth}

If you want the full date, you have to extract to year in the full date
before making the subtraction.

Pierre

ยทยทยท 2014-07-24 2:33 GMT-04:00 Mai Ajjour :

Hey there,

I'm creating an XLSForm to be used on ODK application and I want the user
to enter their date of birth and then to have an equation to calculate the
age- is that possible?

Thanks,
Mai

--

Post: opendatakit@googlegroups.com
Unsubscribe: opendatakit+unsubscribe@googlegroups.com
Options: http://groups.google.com/group/opendatakit?hl=en


You received this message because you are subscribed to the Google Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to opendatakit+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

I have an idea and i want to share it with you.

  1. fisrt of all, create a required field "birthday" and make its
    appearance "year" to make sure to capture the year of the birth day, not
    the full date of birth and its constraint=.<=2014
  2. create a calculated field et make its calculation =2014-${birhtday}
  3. but if you choose to aks for the full date of birth, you have to
    extract the year in the full date before subtracting it to 2014.

Pierre Garraud

ยทยทยท 2014-07-24 2:33 GMT-04:00 Mai Ajjour :

Hey there,

I'm creating an XLSForm to be used on ODK application and I want the user
to enter their date of birth and then to have an equation to calculate the
age- is that possible?

Thanks,
Mai

--

Post: opendatakit@googlegroups.com
Unsubscribe: opendatakit+unsubscribe@googlegroups.com
Options: http://groups.google.com/group/opendatakit?hl=en


You received this message because you are subscribed to the Google Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to opendatakit+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.