[Solved] How to create textfield validation which does not allow blanks / spaces?

0

Hi, for a registration for I would like to have a text field for passport numbers.

I wil use this number later as identifyier and would like respondents not to be able to insert blanks or spaces,

not allowed: “A12 34567″ or ” A12 34567 “

allowed: “A1234567”

 

What string do I have to enter for the validation rule?

 

 

On your help site I found a few examples, but not what I was looking for:

http://help.surveygizmo.com/help/article/link/textbox-answer-formats?_ga=1.266729101.2058222429.1458657053

 

Best regards,

 

Jim W (Moderator) selected answer

    Best answer

    0

    You could use a REGEX validation.

    In the ANSWER FORMAT field, select REGEX.  This allows you to enter various patterns that can be used to validate responses (http://help.surveygizmo.com/help/article/link/textbox-answer-formats#regex-patterns-for-complex-validation).

    I could not find a REGEX pattern specifically for passport ID numbers, but there is one that allows alpha-numeric characters but not spaces (http://regexlib.com/REDetails.aspx?regexp_id=12).

    Jim W (Moderator) selected as best answer
      0

      Hi, 

      Passport number are a set number of characters.  Would imposing a character limit work?  http://help.surveygizmo.com/help/article/link/min-max-word-character

      Thanks,
      Mary

      Mary L (Moderator) answered
        ×

        Login

        Question stats

        • Active
        • Views1248 times
        • Answers2 answers
        • Followers1 follower