AnsweredAssumed Answered

Using checkboxes with IF

Question asked by WilliamMartin_1 on Dec 22, 2015
Latest reply on Dec 22, 2015 by WilliamMartin_1

Hello all,

 

I'm trying to write a script that will check the values of a checkbox set and perform an action based on the contents of the checkbox set.

Here's a sample of what I had written. This does not work as intended but it will hopefully outline what I'm trying to accomplish.

The idea for this sample script is to set another field to either "1" "2" "3" or "4" based on the results of the test.

 

If [ (Table::CheckboxSet = "Box A" & "Box B" & "Box C") & (Table::AnotherField = "Desired Value One") ]

     Set Field [ Table::TestResult ; 1 ]

Else If [ (Table::CheckboxSet ≠ "BoxA" & "Box B" & "Box C") & (Table::AnotherField = "Desired Value One") ]

     Set Field [Table::TestResult ; 2]

Else If [ (Table::CheckboxSet = "Box A" & "Box B" & "Box C") & (Table::AnotherField = "Desired Value Two") ]

     Set Field [ Table::TestResult ; 3 ]

Else If [ (Table::CheckboxSet ≠ "BoxA" & "Box B" & "Box C") & (Table::AnotherField = "Desired Value Two") ]

     Set Field [Table::TestResult ; 4]

 

Thanks in advance!

 

William

Outcomes