I have a form where I want to populate two listboxes with the data stored in Roses and Customers worksheets. The line of code bwith the ** below is what is giving me trouble.
Private Sub UserForm_activate()
Application.Workbooks("xx.xlsm").Activate
ActiveWorkbook.Worksheets("Customers").Range("B2").Select
Do Until IsEmpty(ActiveCell) = True
'loop through the customer table list
lstCustomers.AddItem ActiveCell.Value
ActiveCell.Offset(1, 0).Select
Loop
*****ActiveWorkbook.Worksheets("Roses").Range("A3").Select
Do Until IsEmpty(ActiveCell) = True
'loop through the roses table list
lstProducts.AddItem ActiveCell.Value
ActiveCell.Offset(1, 0).Select
Loop
End Sub
Error: Select method of range class failed
What am I doing wrong?