Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Programming / January 2006

Tip: Looking for answers? Try searching our database.

How to get entries into a list box

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Jill - 19 Jan 2006 19:35 GMT
H, I'm attempting a program to enter data into a list box and I'm having a
few problems, this is my first attempt t a VBA list box. Thank you for any
help you can offer Thanks Jill
Toppers - 19 Jan 2006 20:11 GMT
Jill,
          Some of the ways to populate a listbox.

(Xl2003)

HTH

Private Sub UserForm_Initialize()

ListBox1.RowSource = "Sheet2!a1:a10"
'
' OR
'

ListBox1.RowSource = "MyList"  ' <=== Named range
'
' OR
'
For j = 1 To 10
ListBox1.AddItem "aa" & j   ' or could be range("b" & j) or similar
Next j

End Sub

> H, I'm attempting a program to enter data into a list box and I'm having a
> few problems, this is my first attempt t a VBA list box. Thank you for any
> help you can offer Thanks Jill
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.