S
Sandra Grawunder
I have a main form frmRegistration with 2 subforms,
frmVisitorTitle and frmGuestTitle. I would like the
subforms to be visible only under certain conditions. I
have a radio button option group with 3 choices:
Delegate (value = 1)
Guest (value = 2)
Visitor (value = 3)
The value of this option group is stored in the field
RType. Here's what I am trying to do:
If RType is 1 (Delegate) don't show the subforms.
If RType is 2 (Guest) show frmGuestTitle only.
If Rtype is 3 (Visitor) show frmVisitorTitle only.
Here is the event proc I started, but it doesn't work:
Private Sub RType_AfterUpdate()
Select Case Me.RType.Value
Case 1
Me.frmVisitorTitle.Visible = False
Me.frmGuestTitle.Visible = False
Case 2
Me.frmVisitorTitle.Visible = False
Me.frmGuestTitle.Visible = True
Case 3
Me.frmVisitorTitle.Visible = True
Me.frmGuestTitle.Visible = False
End Select
End Sub
I have written case statements before that worked but
they were based on string values from fields. Is this my
problem because the value obtained from the option group
is numeric?
Thanks for your help,
Sandra G
frmVisitorTitle and frmGuestTitle. I would like the
subforms to be visible only under certain conditions. I
have a radio button option group with 3 choices:
Delegate (value = 1)
Guest (value = 2)
Visitor (value = 3)
The value of this option group is stored in the field
RType. Here's what I am trying to do:
If RType is 1 (Delegate) don't show the subforms.
If RType is 2 (Guest) show frmGuestTitle only.
If Rtype is 3 (Visitor) show frmVisitorTitle only.
Here is the event proc I started, but it doesn't work:
Private Sub RType_AfterUpdate()
Select Case Me.RType.Value
Case 1
Me.frmVisitorTitle.Visible = False
Me.frmGuestTitle.Visible = False
Case 2
Me.frmVisitorTitle.Visible = False
Me.frmGuestTitle.Visible = True
Case 3
Me.frmVisitorTitle.Visible = True
Me.frmGuestTitle.Visible = False
End Select
End Sub
I have written case statements before that worked but
they were based on string values from fields. Is this my
problem because the value obtained from the option group
is numeric?
Thanks for your help,
Sandra G