G
Guest
Hi All,
I have a subform "sfrm_Current_Qtr" on Main form "frm_Compliance_Accounts".
The subform is a done in datasheet view because depending on the record
showing on the main form, there could be up to five records showing in the
sfrm_Current_Qtr. One of the fields in the subform is "Archive". It is a
checkbox that is enabled or disabled depending on whether the "Compliant"
field is "No" or "yes". My problem arises when the subform has multiple
recordswith the Compliant field being "No" in one and "Yes" In another, then
the Archive field is either enabled or disabled on all of the filtered
records depending on what is showing first (yes or no).
Is there anyway to get the Archive field to show both enabled and disabled
if multiple records come up having Yes and no in the "compliant" field?
Here is the code I have thus far:
Private Sub Archive_AfterUpdate()
DoCmd.GoToControl "Action" ' This is used just to move the focus off the
the Archive field
End Sub
Private Sub Form_Current()
If Me.Compliant = "No" And (IsNull(Me.Action) Or Me.Action = 0) Then
Me.Archive.Enabled = False
Else
Me.Archive.Enabled = True
End If
End Sub
Thanks!
I have a subform "sfrm_Current_Qtr" on Main form "frm_Compliance_Accounts".
The subform is a done in datasheet view because depending on the record
showing on the main form, there could be up to five records showing in the
sfrm_Current_Qtr. One of the fields in the subform is "Archive". It is a
checkbox that is enabled or disabled depending on whether the "Compliant"
field is "No" or "yes". My problem arises when the subform has multiple
recordswith the Compliant field being "No" in one and "Yes" In another, then
the Archive field is either enabled or disabled on all of the filtered
records depending on what is showing first (yes or no).
Is there anyway to get the Archive field to show both enabled and disabled
if multiple records come up having Yes and no in the "compliant" field?
Here is the code I have thus far:
Private Sub Archive_AfterUpdate()
DoCmd.GoToControl "Action" ' This is used just to move the focus off the
the Archive field
End Sub
Private Sub Form_Current()
If Me.Compliant = "No" And (IsNull(Me.Action) Or Me.Action = 0) Then
Me.Archive.Enabled = False
Else
Me.Archive.Enabled = True
End If
End Sub
Thanks!