Discussions

Expand all | Collapse all

Hiding fields when box is checked

  • 1.  Hiding fields when box is checked

    Posted 01-30-2018 23:22
    Can't figure out how to do this without getting form errors.  I have 3 checkboxes "1" "2" "3"
    If checkbox 3 is checked I want to show all 4 rows with 4 fields in each row...

    row 1  field 1, field 2, field 3, field 4
    row 2  field 1, field 2, field 3, field 4
    row 3  field 1, field 2, field 3, field 4
    row 4  field 1, field 2, field 3, field 4

    If checkbox 2 is selected I only want to show row 1 and 2...

    row 1  field 1, field 2, field 3, field 4
    row 2  field 1, field 2, field 3, field 4

    If checkbox 1 is selected I only want to show row 1...

    row 1  field 1, field 2, field 3, field 4

    I also don't want to allow more than one checkbox checked at a time.  Any suggestions as I can't seem to get this one figured out.

    Appreciated as always...


  • 2.  RE: Hiding fields when box is checked

    Posted 01-30-2018 23:32
    No problem for your two part question.

    You need to think about each row separately and not think what happens when each check box is checked.  So turn your thinking backwards from what it is now.  I will refer to "Row x" but we know that really means the fields in Row x


    Rule 1
    When multiple conditions are true
    when any
    checkbox 1 is checked
    checkbox 2 is checked
    checkbox 3 is checked

    Show Row 1.

    Rule 2
    When multiple conditions are true
    when any
    checkbox 2 is checked
    checkbox 3 is checked

    Show Row 2.

    Rule 3.
    When multiple conditions are true
    when any

    checkbox 3 is checked

    Show Row 3.


    Then part 2 of your question.

    Three Rules,

    Rule A 
    When checkbox 1 is checked
    Action
    Change Checkbox 2 to unchecked.
    Change Checkbox 3 to unchecked.
    (and remember to uncheck the box that says to only fire when the condition becomes true)

    Rule B 
    When checkbox 2 is checked
    Action
    Change Checkbox 1 to unchecked.
    Change Checkbox 3 to unchecked.
    (and remember to uncheck the box that says to only fire when the condition becomes true)


    Rule C 
    When checkbox 3 is checked
    Action
    Change Checkbox 1 to unchecked.
    Change Checkbox 3 to unchecked.
    (and remember to uncheck the box that says to only fire when the condition becomes true)


  • 3.  RE: Hiding fields when box is checked

    Posted 01-30-2018 23:51
    Thank you so much!  I didn't realize there was a selection for "multiple conditions".  I need to pay closer attention.  I appreciate the quick help tremendously!