I can't figure out why my logic isn't working properly

  • ngoode
    Asked on June 3, 2016 at 2:09 PM

    I'm currently working in the 'Clone' so I don't mess up my original (which hasn't work - but just incase). In question 1 when I select 6 - the conditional logic works by directing me to 'Party of 6'.

    In the next question, I select 5 - which should show the next portion, which works. But when I select '1 or more' on item 6, it should direct me to 'Room Types' and show me 'Family Suite' ONLY. But it shows me 'Apologies' as well, and I can't figure out why.

    I've removed all of my logic and replaced it several times now... and am just stumped!

    Please help! I've just found this site, and think it's incredible and want to pitch it to my company, but need to figure this out asap!!

    Thanks!~

    Natalie

  • David JotForm Support
    Replied on June 3, 2016 at 2:33 PM

    I checked your form and when I select "5" as the number of people, then set the number of children, only the family suite options are shown on the next page:

    I cant figure out why my logic isnt working properly Image 1 Screenshot 20

    The logic appears to be working as you described.  Is it still not working like this on your end?

  • ngoode
    Replied on June 3, 2016 at 2:51 PM

    HI David!!

    Thanks for this!

    It IS still having issues on my end... could it in any way be related to the fact that it's in preview mode? I've had issues with css in other programs in preview, and wonder if publishing it would help?

    I've tried clearing my cache, cookies, and history.. and it's still coming up...

    Here's a screen grab

  • David JotForm Support
    Replied on June 3, 2016 at 3:28 PM

    I think I see what the issue is.  Depending on how many children are selected, the apologies section can be shown:

    I cant figure out why my logic isnt working properly Image 1 Screenshot 20

    Since Apologies will be shown if any of those rules are matched, if "How many children are in your party?" is equal do anything but "4", Apologies will be shown. 

    If you click on the Apologies form collapse and then click on the conditions icon on the field, it will show all the conditions associated with that field.

  • ngoode
    Replied on June 3, 2016 at 3:31 PM

    HI David!

    Yes this is correct.. but if you open all of those conditions you'll notice NONE of them are related to item 6.

    The questions shown in the above are repeated throughout my form - but in different areas / pages.

  • David JotForm Support
    Replied on June 3, 2016 at 3:38 PM

    I checked the conditions for that field in the party of 5 section and there is this condition associated with it:

    I cant figure out why my logic isnt working properly Image 1 Screenshot 20

    This would be showing the Apologies section.

  • ngoode
    Replied on June 3, 2016 at 3:41 PM

    HI David!

    My answer to this question was 5.... so it should NOT be showing then... right?

  • David JotForm Support
    Replied on June 3, 2016 at 3:43 PM

    I am looking at section 5, when 5 people are selected.  If 3 or 4 children are selected, the apologies field is not shown.

  • David JotForm Support
    Replied on June 3, 2016 at 3:44 PM

    If you are looking at section 6, this is the condition showing Apologies:

    I cant figure out why my logic isnt working properly Image 1 Screenshot 20

  • ngoode
    Replied on June 3, 2016 at 3:46 PM

    You're killin me David!

    My answer to this question was 1

     

     

  • David JotForm Support
    Replied on June 3, 2016 at 3:56 PM

    Apologies, I am working off my clone which does appear to work differently from your copy.  My copy works exactly how you are expecting:

    https://form.jotform.com/61545966818975

    You can clone that copy if it is indeed working how you'd like.  I am not sure what is causing the behavior in your form.  Possibly some bugged ID's due to duplicated fields.

    http://www.jotform.com/help/42-How-to-Clone-an-Existing-Form-from-a-URL

  • David JotForm Support
    Replied on June 3, 2016 at 4:00 PM

    It may be caused by the fields still being filled after being hidden.  In which case, enabling clearing field values when hidden may fix it:

    I cant figure out why my logic isnt working properly Image 1 Screenshot 20

    Under form preferences, click "Show More" and change to "Clear On Being Hidden".  This will ensure that hidden fields are not causing conditions to be met.

  • ngoode
    Replied on June 3, 2016 at 4:01 PM

    Hi David!!

    Sounds great! I've deleted mine, and imported your copy.

    Just read your other message! I bet thats what it is, because I would go back thru to test different scenarios!! Perfect!!

    Thank you David! Happy Friday!~

  • Mike_G JotForm Support
    Replied on June 3, 2016 at 6:01 PM

    On behalf of my colleague, david, you are most welcome! Please feel free to contact us anytime if you have any other questions or concern. 

    Thank you.