I have a form where I need my check boxes to become hidden whenever a quantity is entered in a particular subform section. I don't want the users to be able to close the section they are in if there is a quantity in any of the fields in that section, since it leaves the information still. I have come close, but can't quite get it. It seems like it would be simple. I have attached my file.
My thought is to have it be on the SubQty field in each subform section. That if any of the qty fields in that subform section have a value, that the check box would be hidden, and if there are no values in any of them, that it would be visible. For example, if you click on the Distribution check box, that subform section opens. Then if a quanity were entered in the ADS quantity field, the Distribution check box would become hidden. Then if that quantity was deleted, it would become visible again. So if any of those qty fields in Distribution had something in them, the check box is hidden, if they are all deleted/empty, it would be visible.
Any help with this would be greatly appreciated.
You could write a IF clause on exit event of each Qty field, so you verify if the field is empty or not. Then you do something like this:
form1.P1.TestBlock.CtrlBlock.DistributionCheckbox.presence = "invisible";
or visible, case else.
I hope can help.