superfly5203
Registered User.
- Local time
- Today, 16:47
- Joined
- Apr 5, 2016
- Messages
- 43
Hello,
I'm making a new database and I have some fields that I'm hiding when a checkbox isn't selected. I have about 20 or so fields that I want to make a group so I don't have to type them all in, along with the labels for each of them. Is that possible?
Also I have noticed that in my form when I go to a previous entry even if the box is checked to show a field, the field isn't there. I'll have to uncheck the box and then recheck it for the field to show up. What code do I need to have to make it so when i cycle through entries the fields will show up based on the boxes that are checked for that specific entry?
here is the code that I have been using:
Private Sub UCA_AfterUpdate()
If Me.UCA = True Then
Me.CCO_Mod_Number.Visible = True
Me.CCO_NTE_Value.Visible = True
Me.Date_CCO_Mod_Signed.Visible = True
Me.Label5.Visible = True
Me.Label6.Visible = True
Me.Label7.Visible = True
Else
Me.CCO_Mod_Number.Visible = False
Me.CCO_NTE_Value.Visible = False
Me.Date_CCO_Mod_Signed.Visible = False
Me.Label5.Visible = False
Me.Label6.Visible = False
Me.Label7.Visible = False
End If
End Sub
Thanks for any help!
I'm making a new database and I have some fields that I'm hiding when a checkbox isn't selected. I have about 20 or so fields that I want to make a group so I don't have to type them all in, along with the labels for each of them. Is that possible?
Also I have noticed that in my form when I go to a previous entry even if the box is checked to show a field, the field isn't there. I'll have to uncheck the box and then recheck it for the field to show up. What code do I need to have to make it so when i cycle through entries the fields will show up based on the boxes that are checked for that specific entry?
here is the code that I have been using:
Private Sub UCA_AfterUpdate()
If Me.UCA = True Then
Me.CCO_Mod_Number.Visible = True
Me.CCO_NTE_Value.Visible = True
Me.Date_CCO_Mod_Signed.Visible = True
Me.Label5.Visible = True
Me.Label6.Visible = True
Me.Label7.Visible = True
Else
Me.CCO_Mod_Number.Visible = False
Me.CCO_NTE_Value.Visible = False
Me.Date_CCO_Mod_Signed.Visible = False
Me.Label5.Visible = False
Me.Label6.Visible = False
Me.Label7.Visible = False
End If
End Sub
Thanks for any help!