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 John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

fill 2nd Combobox

Status
Not open for further replies.

mar050703

Technical User
Aug 3, 2007
99
GB
I have the following code for my fost combobox;
Code:
Private Sub Userform_Initialize()

    Dim ws As Worksheet
    
    Set ws = Worksheets("Employees")
    Set MyRange = ws.Range("A2", ws.Range("A150").End(xlUp))
    
With Me.Employee
.RowSource = ws.Name & "!" & MyRange.Address
.ListIndex = 0
End With

End Sub
I want to now fill out the 2nd combobox so if the 1st says 'Accounts' then the second will give all the names of those in accounts (column B of the above worksheet).

I am not sure where to start
 

On the click event of your 1st combo, add code that fills the second
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top