Question T1324
Visible to All Users

Validation for year field

created 6 years ago

Hi Team,

I'm trying to use validators to validate a field which contains year value. I want to check the value is always =< current year. Is there anyway I can do this without using custom validators?

Regards,
Sandesh

Answers

created 6 years ago

Hello,

No, SurveyJS library doesn't contain such a code.

Thanks, Serge
SurveyJS Team

    Comments (2)

      Hello,

      But you can find this sample useful - https://next.plnkr.co/edit/y3F5wY4QCs58O9g1?preview
      It uses expression validator with custom function.

      Thanks, Serge
      SurveyJS Team

      SD SD
      Sandesh DSouza 6 years ago

        Hi Serge,

        Sorry for the late response. Yes, that's what I have done. Thanks for your help.

        Regards,
        Sandesh