How do I use conditional logic to auto select items from a check box list?

  • oztechs
    Asked on July 6, 2016 at 10:06 PM

    I have a form with 2 checkbox fields.

     

    Checkbox Field A

      Example 1
      Example 2
      Example 3

    Check box Filed B

    Option 1
    Option 2
    Option 3
    Option 4
    Option 5

    When i select Example 1 I want Option 1 and 2 to be pre selected.

    When I choose Example 2 then I want Options 2 and 4 auto selected.

    So when I use the conditional logic I can only say If Field A is equal to Example 1 then enable ... and that is where my problem I can only enable the entire widget and I can't specify: Field B, Option 1, Option 2.

     

    Is there away to achieve that?

     

    Thank you,

     

    OZ

  • Kevin Support Team Lead
    Replied on July 6, 2016 at 10:56 PM

    Unfortunately this is not possible, you can only copy the selection from one check box to another one, but fields must have the same options in order to copy the selected option. 

    Here is a sample form that I made to show you how it works: https://form.jotform.com/61878285666979 

    This seems to be the only way to handle two different check boxes, otherwise you will need to get the source code of your form and add your custom script code to achieve it. 

  • oztechs
    Replied on July 7, 2016 at 1:19 PM

    Randy,

     

    Your solution is what I am looking for, that looks great.  Now how do I implement it?

     

    Thank you so much.

     

    OZ

  • oztechs
    Replied on July 7, 2016 at 1:32 PM

    OK, I figured how to import the form into my forms, thank you, I will learn how you did it.  Your help is much appreciated.

  • BJoanna
    Replied on July 7, 2016 at 2:30 PM

    Thank you Randy for providing this great workaround. 

    @oztechs 

    Once you clone the form Randy provided, you can inspect conditions that are set inside of the form. All conditions that were used are Update / Calculate Field. 

    How do I use conditional logic to auto select items from a check box list? Image 1 Screenshot 20

    If you have difficulties with applying this to your form, please provide us ID of the form you are working on and tell us which fields you want to pre-select based on another field selection. 

    Let us know if you need further assistance.