View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default Not getting hoped for result

I'd use:

With Worksheets("Friday Workshifts")
me.ListBox1.RowSource = .range("$A$2:$R$200").address(external:=true)
End With

And not have to ever worry about the syntax.

"Patrick C. Simonds" wrote:

This code is using the current (active) Worksheet to provide the list data
not Friday Workshifts. Can any one tell me what I have missed?

Private Sub UserForm_Initialize()
With Worksheets("Friday Workshifts")
ListBox1.RowSource = "$A$2:$R$200"
End With
End Sub


--

Dave Peterson