If a condition changes a checkbox to read-only after you manually checked it, the checkbox will become unchecked after the next postback.
A workaround solution is to add the
aslist custom attribute set to
true in the checkbox’s custom attributes.
Note that doing this will impact the checkbox value saved in the form data:
Before adding the
aslistattribute, a single checkbox will save the value
false, whether it is checked or not.
After adding the
aslistattribute, however, the single checkbox will save the value defined in the option value field of the checkbox properties.