Page 1 of 1

how to add a checkbox to a insert transaction?

Posted: 2010-05-24 10:18
by piripacchio
Hi all,
I have a insert transaction on page.
I would like to add a checkbox that need to be checked when inserting the record.
The problem here is that there is no field in the database linked to this checkbox.
Is there a way to validate the form (using the checkbox) without having a specific field in the database?

TIA

tony

Re: how to add a checkbox to a insert transaction?

Posted: 2010-05-24 13:39
by Fred
Hi Tony,
I haven't tried this because I usually record the ticked value even if it is set to "required" in the field validation.

I guess you can start with adding a "Throw Error" behaviour.

Lets say the name of the checkbox is "checkbox".
In the "Advanced" tab enter your condition as follows:

Code: Select all

{POST.checkbox} != 1
That way you can at least check the value of the box.
The only problem is you need to link it to a transaction field and display an error message