Hi,
I would like to know if there is a way to check a checkbox in every record base on 1 check box outside that form?
The main form has the checkbox 'chkReceivedAll' and the subform 'frmReceivedSud' has a checkbox on every record call 'chkReceived'.
So when the user check the 'main' checkbox i would like that all checkboxes in the subform to be'check'.
I'm playing with this code with not much luck:
Can this be done?
Thanks
I would like to know if there is a way to check a checkbox in every record base on 1 check box outside that form?
The main form has the checkbox 'chkReceivedAll' and the subform 'frmReceivedSud' has a checkbox on every record call 'chkReceived'.
So when the user check the 'main' checkbox i would like that all checkboxes in the subform to be'check'.
I'm playing with this code with not much luck:
Code:
Dim ctr As Control
Dim FirstNull As CheckBox
For Each ctr In Me.Controls
If ctr.ControlType = acCheckBox Then
If IsNull(ctr) Then
If FirstNull = "" Then
ctr.SetFocus
ctr.Checked = True
End If
FirstNull.Value = True
End If
End If
Next
Thanks