Populating combobox from another combobox
Hello
I've created, with help, a combobox that lists the sheets in a workbook. I now want a second combobox to be populated from the contents of a specific range from the sheet chosen in combobox 1. ie combobox1 = company names (held in sheet) combobox2 = above company - employee names held in range(A2:A30) Again any help is greatly appreciated. Thanks David |
Populating combobox from another combobox
use the click event of the first combobox
Private Sub Combobox1_Click() Dim sName as String if Combobox1.ListIndex < -1 then sName = Combobox1.Value Combobox2.RowSource = sName & "!A2:A30" End if End sub -- Regards, Tom Ogilvy "David Goodall" wrote in message ... Hello I've created, with help, a combobox that lists the sheets in a workbook. I now want a second combobox to be populated from the contents of a specific range from the sheet chosen in combobox 1. ie combobox1 = company names (held in sheet) combobox2 = above company - employee names held in range(A2:A30) Again any help is greatly appreciated. Thanks David |
All times are GMT +1. The time now is 03:06 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com