G
Guest
I have a Parent form with several subforms (located in tabs). I was able to
see/hide fields in one form based on the values in another form using code
like this:
Private Sub ImmunizationHistory_GotFocus()
If Forms![SPCA]![PetInfo].Form!PetType = "Dog" Then
Me.CatRunnyEyesNose.Visible = False
Me.CatFleaCollarHarness.Visible = False
End If
I've tried to replicate this procedure in another subform that tries to
examine boolean (yes/no) fields using code like this:
If Forms![SPCA]![Services].Form![Rabies] = True Then
Me.Rabies.Visible = True
Me.RabiesTag.Visible = True
End If
When I run the program, however, I get the following message: "Microsoft
Office Access, can't find the field 'SERVICES' referred to in your
expression." This subform was under a tab named "SERVICES" so I renamed the
tab 'APPLICATION' and have confirmed that the form name I'm trying to call is
"Services"...I'm stumped. There is a table named 'Services' but I can't
imagine this being the problem. Any suggestions? (Also, is there anything
special I need to know about referrring to subforms that are parked under a
tab?).
see/hide fields in one form based on the values in another form using code
like this:
Private Sub ImmunizationHistory_GotFocus()
If Forms![SPCA]![PetInfo].Form!PetType = "Dog" Then
Me.CatRunnyEyesNose.Visible = False
Me.CatFleaCollarHarness.Visible = False
End If
I've tried to replicate this procedure in another subform that tries to
examine boolean (yes/no) fields using code like this:
If Forms![SPCA]![Services].Form![Rabies] = True Then
Me.Rabies.Visible = True
Me.RabiesTag.Visible = True
End If
When I run the program, however, I get the following message: "Microsoft
Office Access, can't find the field 'SERVICES' referred to in your
expression." This subform was under a tab named "SERVICES" so I renamed the
tab 'APPLICATION' and have confirmed that the form name I'm trying to call is
"Services"...I'm stumped. There is a table named 'Services' but I can't
imagine this being the problem. Any suggestions? (Also, is there anything
special I need to know about referrring to subforms that are parked under a
tab?).