Re: Dynamic Form display based on date of birth

Moritz_Trollman
Level 3

Dynamic Form display based on date of birth

Hi I would like to show a form field only to people that were born within the last 20 years.

Any suggestions on how to build this dynamically without having to update the rule for this every couple of weeks ?

Thanks,

Moritz

4 REPLIES 4
Josh_Hill13
Level 10 - Champion Alumni

Re: Dynamic Form display based on date of birth

I assume you have people's birthdates?

You should be able to create a segmentation that says:

Date of Birth IN PAST 20 Years

vs.

Default. (everyone else)

SanfordWhiteman
Level 10 - Community Moderator

Re: Dynamic Form display based on date of birth

My thought was definitely the same: this is a great example of when to use a segmentation.  Another way to accomplish the same would be form prefill and dynamically checking their age on the client.

But -- this is a question for Moritz -- I was musing about it a minute ago, and in the case when someone was under 20 at acquisition, do you want to age them out if they turn 21 while you're still marketing to them (and you don't have any other data to keep them in the same segmentation)?  Just something to be mindful of, and maybe it is exactly what you want.

Moritz_Trollman
Level 3

Re: Dynamic Form display based on date of birth

Thank you for your replies.

Your suggestion will work for leads that are already in the database.

The challenge is to dynamically display the field also for new leads at the time of the form fillout.


I tried to use visibility rules based on the birthdate. This is however limiting as I cannot select days, weeks or years when choosing "in past" or any other available criteria.

I looked into using a custom formula field but i could not pull this into the form. Also I am not sure if this even works.

SanfordWhiteman
Level 10 - Community Moderator

Re: Dynamic Form display based on date of birth

Ah, if you're talking about at form fillout you will need some Forms 2.0 JS. I'll post it for you later tonight as I'm in meetings all day.

(Note a back-end formula field couldn't possibly work because that would have to be based on data already stored on the lead, and as you point out you don't have data on the lead yet.)