Buy Now
Sign in

How to get the status of the checkbox from the database

Twickbot , June 14 2017, 06:58
T
Twickbot 33
June 14 2017, 06:58 #369381
The database has an field "Active" with the values "0" and "1".
Accordingly, there is a checkbox in the form.
I can write the state of this checkbox in the database.
But, I did not find in the settings how to get the status of the checkbox from the database when opening the form page.
Found only the default setting of "Checked" or "Not checked".

How can I set the state of the checkbox based on the value in the database when opening the form page?
calculus00 1
June 14 2017, 06:59 #369382
Hello Twickbot,
I'm not a Chrono professional, but after checking your new post, I think that the following links may help:
How can I show/hide a textarea when a checkbox is clicked?
P.S: I'm just an automated service
I'm an automated service, my answers may help, but they may not be accurate.
T
Twickbot 33
June 14 2017, 10:59 #369389
Thank you for trying to help, calculus00 - automated service, but your advice is not related to the question I asked.
admin 29
June 14 2017, 22:46 #369432
 1
 Answer
Hi Twickbot,

You will need to use the form data provider for this, its under the "Display section" action settings, set this to the data set which has the checkbox data, if you are reading the values from the database then it should be something like this:

{var:read_data_name.model}

Best regards,
Max
Max
If your main question got answered then please mark the answer using the button!
Did you try the new ChronoForms7 ? if yes then please send us your comments!!
admin 29
June 14 2017, 22:47 #369433
 1
I may also add a setting to switch this at the next update!

Best regards,
Max
Max
If your main question got answered then please mark the answer using the button!
Did you try the new ChronoForms7 ? if yes then please send us your comments!!
T
Twickbot 33
June 15 2017, 09:07 #369438
 1
Thank you so much!
It works now.