I have a combobox in a userform, and I would like for the options to be from a dynamic range within my workbook. Generally, I use this code to make it work:
This code has worked fine, but I have recently hit a snag. If I am viewing a different worksheet than the range is on, I get an error. This is a problem because I have information on a hidden worksheet that I would like to populate the combobox. Does anyone have any suggestions?Private Sub Userform_Initialize() ComboBox1.List = Sheets("Sheet1").Range("A1", Range("65536).End(xlUp)).Value End Sub
Bookmarks