What is JotForm?
JotForm is a free online form builder which helps you create online forms without writing a single line of code. No sign-up required.

At JotForm, we want to make sure that you’re getting the online form builder help that you need. Our friendly customer support team is available 24/7.

We believe that if one user has a question, there could be more users who may have the same question. This is why many of our support forum threads are public and available to be searched and viewed. If you’d like help immediately, feel free to search for a similar question, or submit your question or concern.


  • Profile Image

    Help with condition logic

    Asked by zaccopp on March 26, 2012 at 09:48 AM

    I created a simple form to illustrate my problem (my actual form is more complex, but having the same results).  I created a drop down field that allows you to select a number (1 through 4)...I am visualizing this number corresponding the total number of people that I want information for.  Accordingly, I then have 4 corresponding text fields (Name # 1; Name # 2; Name # 3; and Name #4). 

    What I want to achieve is: When you select Number 1, only the text field for Name # 1 should be visable (Name #s 2, 3, and 4 should be hidden). 

    Here is my logic for the above:

    If 1, hide Name # 2

    If 1, hide Name # 3

    If 1 hide Name # 4

    Likewise, when Number 2 is selected, only text fields for Names 1 and 2 shoud be visable (Name #s 3 and 4 should be hidden) and when 3 is selected, Name # 4 should be hidden.

    Thus the additional logic would be:

    If 2, hide Name # 3

    If 2, hide Name # 4

    If 3, hide Name # 4

    For some reason, the combined logic above results in the following results:

    If 1 is selected, then only Name # 2 is hidden (not 2 through 4)

    If 2 is selected, then only Name # 3 is hidden (not 3 and 4)

    Is my logic faulty?

    Thanks in advance,

    Zac

    Page URL:
    http://form.jotform.us/form/20853335284151

  • Profile Image
    JotForm Support

    Answered by NeilVicente on March 26, 2012 at 11:14 AM

    Zac,

    Did you know that you can add multiple rules for each action?

    If you want to hide Name 3 when either one of options 1 and 2 is selected, instead of two separate conditions:

    You can just consolidate them into one condition by using the Add New Rule option:

     

    Doing so will make your conditions more streamlined and less prone to logic faults.

    Click here to see an improved version of your sample form. You may also want to clone it so you can examine what I did with the conditions.