Show/Hide field base on country selected is not working.

  • transpay
    Asked on April 8, 2016 at 2:42 PM

    I have a rule on my form that if

    1. Country is filled, AND

    2. Country does not equal Pakistan

    THEN

    1. Show text "Sorry, only freelancers based in Pakistan are allowed to participate in this survey.", AND

    2. Hide "Page Break"

     

    However, when I try to select a country other than Pakistan, neither of the actions occur. 

  • Mike_G JotForm Support
    Replied on April 8, 2016 at 4:18 PM

    If that is what you want you can just remove the rule, "If Country is Filled". 

    Show/Hide field base on country selected is not working Screenshot 30

    I noticed that you used the address field and just get the Country field. And that country field is filled by default.

    May I suggest you use a drop-down field with a special option of "Countries" instead?

    The drop-down field will remain empty until a selection is made. This way, the condition would be executed perfectly.

    Show/Hide field base on country selected is not working Screenshot 41

    I hope this helps. Let us know if you need any further assistance. Thank you.

  • transpay
    Replied on April 8, 2016 at 4:20 PM

    Thanks. If I was to add a new country field, is it possible to transfer all responses from the current country field to the new field? It says if I delete a field all coinciding data will disappear.

  • Mike_G JotForm Support
    Replied on April 8, 2016 at 5:50 PM

    I would like to apologize, however, after I have made some tests, I found out that it would not be possible since they have different values. The country field from the address field has "Country:" that comes first before the country that was selected. Aside from that, you are correct, replacing the fields would delete existing data of previous submissions on your form. I would suggest, since your issue with the current country field on your form is already fixed, you can just stick with the country field of the address field.

    Thank you.

  • transpay
    Replied on April 8, 2016 at 6:42 PM

    How is it fixed? Are we seeing something different? I'm still seeing the same problem.

  • Nik_C
    Replied on April 8, 2016 at 10:39 PM

    Let us investigate this a bit more and we'll get back to you.

    Thank you!

  • Nik_C
    Replied on April 8, 2016 at 11:15 PM

    I did some tests on your form. What worked for me, as my colleague Mike suggested, is adding drop-down menu and making conditions use that field. 

    Show/Hide field base on country selected is not working Screenshot 20

    So, I added drop-down to the form and made calculation as you requested, and that is working.

    Please check my clone of your form, feel free to test it or to clone it to your forms: https://form.jotform.com/60988313641965

    Hope it helps.