Make subform dissappear when ...

  • Thread starter Thread starter Sue Compelling
  • Start date Start date
S

Sue Compelling

Hi ALL

I would like the following action to occur though don't know how to make it
happen (by code)

I have a form called "Contacts"

When the user selects the contact status of Individual or Bequestor (an
option box selection which equates to 1 or 10 populating the field "Type")
then I want the subform called "ContactsOrg subform" to dissappear -
otherwise I want the subform to stay "on top" of the fields that would be
filled in for an individual.

TIA
 
OK

I've made it work MOSTLY but with one slight hitch

I can make labels, firleds and subforms dissapear when the uer selects "1"
but I don't know how to also add the condition when the user select 10.
(have tried and, or and multiple other things)

TIA

My code is ...

Private Sub Form_Current()

Me![contactsorg subform].Form.Visible = False = (Me.Type = 1)
Me.Org_NameLabel.Visible = False = (Me.Type = 1)
Me.OName.Visible = False = (Me.Type = 1)
Me.OrgContacts_Label.Visible = False = (Me.Type = 1)
Me.Website.Visible = False = (Me.Type = 1)
Me.Website_Label.Visible = False = (Me.Type = 1)
 
Back
Top