I am trying to force the user to enter their age but not less than 17 from the current year.

I am trying to force the user to enter their age but not less than 17 from the current year.

Hello,
I tried it. I receive this error.

You might needed to also use the formatter to convert to date. I’m not at my computer at the moment so can’t provide screenshots.
You might also check this post ...
I checked it. I think i understood a little bit but I just don’t even want to bother giving them access to the database and put it their birthday is not meeting the requirement of the site.
This is going to need more than just a min of the value, it first needs to know the current date.

The code should look like
<dmx-datetime id="var1"></dmx-datetime>
<input id="text1" name="text1" type="number" class="form-control" dmx-bind:min="var1.datetime.addYears(-17).getYear(var1.datetime)" required="">
Thank you for your help. 
It is working perfectly.