View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
PC[_3_] PC[_3_] is offline
external usenet poster
 
Posts: 22
Default Populate Excel Userform with Sheet names

Hi,

I'm using this piece of code to populate an excel userform listbox with the
name of each worksheet in a workbook

i = 1
For Each ws In Worksheets
Worksheets.Select
Sheets(i).Activate
ListBox1.AddItem (ActiveSheet.Name)
i = i + 1
Next ws


Is there a better way I can do this as this visably activates each
sheet each time the listbox is repopulated.

Thanks

...pc