How to conditionally display fields based on the user response

  • Info_Realty
    Asked on April 20, 2024 at 12:33 PM

    https://form.jotform.com/241095711970154

    The above URL is for a form that I am creating by which a user is permitted to save information via the form (because it is a long form) and also, of course, go back on the form .

    I have found though that if a user accidentally answers a question that has conditional logic and fills out the corresponding field, if they change the initial question answer, it still leaves the now not applicable conditional logic field with the information inserted.I need the whole field to disappear if the end user's answer changes the corresponding logic, because that information is not relevant and would be confusing.

    An easy example on my form is if the end user select's Sellers and then is prompted to insert Seller information, but if they hit the back button and change Seller to Buyer, as you can see in the screenshot below, the Buyer field pops up but the Seller field remains displayed. Even when you erase the information the Seller field remains and because it is required, forces the end user to put information to even move on to the next page of the form.

    How to conditionally display fields based on the user response Image 1 Screenshot 20

    What is a work around so that this does not happen WITHOUT having to re-fresh and re-do the form, which does solve the problem, but is not ideal?

  • Info_Realty
    Replied on April 20, 2024 at 1:03 PM

    THIS IS NOT ANSWER, but another example of where a user can insert the wrong information, but still have access to the see field - what is the appropriate logic to make this situation not happen?

    The logic keeps breaking at the conditional logic of the second string whose answer


    How to conditionally display fields based on the user response Image 1 Screenshot 40

    How to conditionally display fields based on the user response Image 2 Screenshot 51How to conditionally display fields based on the user response Image 3 Screenshot 62

  • Lesther JotForm Support
    Replied on April 20, 2024 at 4:55 PM

    HI Info_Realty,

    Thanks for reaching out to Jotform Support. I'm currently working on your concern. Please give me more time to look into it. I'll get back to you as soon as possible.

  • Lesther JotForm Support
    Replied on April 20, 2024 at 5:25 PM

    HI Info_Realty,

    Thanks for using Jotform. I modified the form fields display option. Those field that should be displayed conditionally based on the user response, I hide them by default. Just right-click on them and then select Hide from the option. I also modified the conditions attached to these fields and removed any action that will hide them. See the following screenshots:

    How to conditionally display fields based on the user response Image 1 Screenshot 30

    I modified the conditions to include the IF statement "IF the field is filled and IF the value is equal to" so that when the user changes their response to a field, it will discard the previous response and will focus on the other logic attached to the field. An example is highlighted on the screenshot below. If the field "How many Buyer(s) are party to the Purchase & Sale Agreement?" is filled and if the value is equal to "1", it will display the field "Buyer's Information".

    How to conditionally display fields based on the user response Image 2 Screenshot 41

    The same concept applied to the other fields. Test my demo form on this link. Clone it to own a copy and be able to see the entire setup. Here's the guide on How to Clone an Existing Form From a URL.

    Let us know if you have any other questions. 

 
Your Answer