View Full Version : Populate a list box with worksheet names

04-27-2015, 01:04 PM
In my user form, how would I populate the list box with worksheet names (excluding the first two worksheet names), not manually inputting each worksheet name?

Thank you for any help!

04-27-2015, 01:29 PM
One more question about this user form... I have a set of three options (max, min, average), when I have the user form activated is there a way to select which option is selected to begin with?

04-27-2015, 08:30 PM
Like this?

Private Sub UserForm_Initialize()
Dim j As Long
For j = 3 To ActiveWorkbook.Sheets.Count
ListBox1.AddItem Sheets(j).Name
Next j
End Sub

The second question need some more explaining. Do you mean "SetFocus"?