View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
[email protected] philipl@vistatec.ie is offline
external usenet poster
 
Posts: 6
Default adding a listbox to a spreadsheet

"Tom Ogilvy" wrote in message ...
Sub TesterAAA3()
Dim rng As Range
Set rng = ActiveSheet.Range("B9:C15")
With ActiveSheet.OLEObjects.Add( _
ClassType:="Forms.ListBox.1", _
Link:=False, _
DisplayAsIcon:=False, _
Left:=rng.Left, _
Top:=rng.Top, _
Width:=rng.Width, _
Height:=rng.Height)
.ListFillRange = "Sheet3!A1:A20"
End With

End Sub

--
Regards,
Tom Ogilvy



wrote in message
om...
hi,

Does anyone have any code sample on how you would add/populate a
listbox in a spreadsheet?

thx
-Philip


thanks that gave me a start