I have a table that has an amount and a checkbox next to it that says refunded. I need to be able to calculate a value based off if that refunded checkbox is checked. I've attached a screenshot below.
I have a table that has an amount and a checkbox next to it that says refunded. I need to be able to calculate a value based off if that refunded checkbox is checked. I've attached a screenshot below.
Sorry - I assumed you were working on a calculation in each row.
If you are doing a calculation outside the table, then a function like SUMIF would probably work. Here's an example:
=SUMIF(table_variable.checkbox_variable.checkbox_value, FALSE, table_variable.amount_value)
This is saying to sum up all amounts from the table on rows where the checkbox is not marked.
EDIT TO ADD: Help Documentation on Formulas in Forms 11
You should be able to use the IF and INDEX functions to check if the checkbox is marked, and then complete a calculate if it is true or an alternate calculation if it is false.
It'll look something like this:
=IF(INDEX(table_variable.checkbox_variable.checkbox_value, ROW()), INDEX(table_variable.amount_variable, ROW())*-1,INDEX(table_variable.amount_variable, ROW()))
This is saying - if the checkbox on this row is marked, the take the amount from this row and multiply it by -1, otherwise take the amount from this row and don't change it.
I have a box with a grand total amount. The sum would be calculated based off if the box was checked "Refunded". Would this still work?
Sorry - I assumed you were working on a calculation in each row.
If you are doing a calculation outside the table, then a function like SUMIF would probably work. Here's an example:
=SUMIF(table_variable.checkbox_variable.checkbox_value, FALSE, table_variable.amount_value)
This is saying to sum up all amounts from the table on rows where the checkbox is not marked.
EDIT TO ADD: Help Documentation on Formulas in Forms 11
That worked. Thank you!
You're welcome.