Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Making a combo visible depending on the selection of another combo

Status
Not open for further replies.

Diezz

Technical User
Dec 24, 2004
61
NL
Hello,

I have 2 combo box, 1: cboTypePb, 2: cboMVS. The second combo box has .visible = false. I want it to turn true for a certain record in the first combo so this is what i've done.

Private Sub cboTypePb_Change()
If cboTypePb.Value = "Applications MVS" Then
cboTypePb.SetFocus
[MVS Application_Label].Visible = True
cboMVS.Visible = True
chkExplicationMVS.Visible = True
Else
cboTypePb.SetFocus
[MVS Application_Label].Visible = False
cboMVS.Visible = False
chkExplicationMVS.Visible = False
End If

This dosen't work, do you have any ideeas?

Thanks
 
I think you should do this in the After Update event.

If cboTypePb is based on an ID and a Description, it is quite likely that it is equal to say, 1, rather than "Applications MVS". You can use a message box to test.

I do not think you need the Set Focus lines.
 
That worked, pf i don't know what i would do without this Forum.

Thanks alot!:)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top