S
scottypws via AccessMonster.com
Hello,
I need your assistance regarding the visibility of a field and its associated
label. I want to hide the visibility of a particular label and associated
field for each record from a query that that is the source to the form.
I use the check box named "Grievance_Filed" to activate the visibility of a
particular label and field. Whenever I click the check box the label and
field appears; and when I unchecked the check box, the field and label
disappears. For a single record at the outset when the form opens, this is
no problem.
PROBLEM: When I initially click the check box in the first record, the label
and field appears.
However, when I navigate to the second record, the label and field is visible
even though the check box is not checked.
I thought that setting the visibility to "No" for the field and label would
take care of the problem, but it doesn't.
REQUESTED ASSISTANCE: How to stabilize the visibility for a label and
associated filed to "No" for all records; and only show the visibility when
the check box is checked.
In the Design mode of the form, I have set the Visibility for the following
label and associated field to "No".
lblGrievanceNbr
txtGrievanceNbr
I have embedded the following code in the AfterUpdate event of the check box:
Quote:
Private Sub Grievance_Field_AfterUpdate()
' When checkbox is checked
If Me.Grievance_Field = True Then
' Show the label and field
lblGrievanceNbr.Visible = True
txtGrievanceNbr.Visible = True
Else
'Do not show label and field
lblGrievanceNbr.Visible = False
txtGrievanceNbr.Visible = False
End If
End Sub
Your help is greatly appreciated.
Scotty
I need your assistance regarding the visibility of a field and its associated
label. I want to hide the visibility of a particular label and associated
field for each record from a query that that is the source to the form.
I use the check box named "Grievance_Filed" to activate the visibility of a
particular label and field. Whenever I click the check box the label and
field appears; and when I unchecked the check box, the field and label
disappears. For a single record at the outset when the form opens, this is
no problem.
PROBLEM: When I initially click the check box in the first record, the label
and field appears.
However, when I navigate to the second record, the label and field is visible
even though the check box is not checked.
I thought that setting the visibility to "No" for the field and label would
take care of the problem, but it doesn't.
REQUESTED ASSISTANCE: How to stabilize the visibility for a label and
associated filed to "No" for all records; and only show the visibility when
the check box is checked.
In the Design mode of the form, I have set the Visibility for the following
label and associated field to "No".
lblGrievanceNbr
txtGrievanceNbr
I have embedded the following code in the AfterUpdate event of the check box:
Quote:
Private Sub Grievance_Field_AfterUpdate()
' When checkbox is checked
If Me.Grievance_Field = True Then
' Show the label and field
lblGrievanceNbr.Visible = True
txtGrievanceNbr.Visible = True
Else
'Do not show label and field
lblGrievanceNbr.Visible = False
txtGrievanceNbr.Visible = False
End If
End Sub
Your help is greatly appreciated.
Scotty