Hello,
Could anyone help me with the code necessary to uncheck or check a checkbox on a form? Let's say there is a button, and I want that button when clicked to automatically check a check box. My actual goal is to have code that loops through all the checkboxes on the form, if they are checked it unchecks them and rechecks them, if they are unchecked it leaves them alone.
Thank you
Solved! Go to Solution.
Views
Replies
Total Likes
if (checkBox.rawValue != 1){
checkBox.rawValue = 1;
}
That should check the box if it isn't. Make sure that if you changed your on/off values, though, that your script reflects that. Setting the rawValue to 1 assumes that your on value is the default 1 and your off value is the default 0.
Ryan D. Lunka
Cardinal Solutions Group
rlunka@cardinalsolutions.com
Views
Replies
Total Likes
if (checkBox.rawValue != 1){
checkBox.rawValue = 1;
}
That should check the box if it isn't. Make sure that if you changed your on/off values, though, that your script reflects that. Setting the rawValue to 1 assumes that your on value is the default 1 and your off value is the default 0.
Ryan D. Lunka
Cardinal Solutions Group
rlunka@cardinalsolutions.com
Views
Replies
Total Likes