| | |
ArrayList to ListBox
Please support our VB.NET advertiser: Intel Parallel Studio Home
![]() |
•
•
Join Date: Jul 2008
Posts: 86
Reputation:
Solved Threads: 0
Hello everyone i am getting input from the user in the form of an inputbox. The inputbox then dumps the information into an arrayList which then i want my Listbox to be populated by the items within the arrayList.
so...
userName = InputBox -> arrayList.add(userName) - > Listbox.items.add(arrayList)
Here is some of my code.
It gives me the error at the bold highlighted text. Any ideas?
so...
userName = InputBox -> arrayList.add(userName) - > Listbox.items.add(arrayList)
Here is some of my code.
userName = InputBox("Enter Name: ")
Dim users As ArrayList = New ArrayList()
users.Add(userName)
For i As Integer = 0 To users.Count
termListBox.Items.Add(users.Item(i))
Next iIt gives me the error at the bold highlighted text. Any ideas?
•
•
Join Date: Dec 2002
Posts: 461
Reputation:
Solved Threads: 56
try:
VB.NET Syntax (Toggle Plain Text)
For i As Integer = 0 To users.Count -1
Wayne
It is hard to understand how a cemetery can raise its burial rates and blame it on the cost of living.
It is hard to understand how a cemetery can raise its burial rates and blame it on the cost of living.
•
•
Join Date: Dec 2002
Posts: 461
Reputation:
Solved Threads: 56
Double click on the My Project. On the left hand side toward the bottom in the Shut Down Mode select "After last form closes".
If you don't then when you close the startup form the program ends.
If you don't then when you close the startup form the program ends.
Wayne
It is hard to understand how a cemetery can raise its burial rates and blame it on the cost of living.
It is hard to understand how a cemetery can raise its burial rates and blame it on the cost of living.
![]() |
Similar Threads
- vb.net 08 Reading data from multiple reg keys (VB.NET)
- How to send values of list box from jsp to an action ?? (JSP)
- multiColumn control passing values to listbox and back (ASP.NET)
- How to get the contents of the column to an arraylist (VB.NET)
- Help me to develop Messenger Project (IT Professionals' Lounge)
- Need Help Regarding MultiThreading (ASP.NET)
- Open a text file from another project (VB.NET)
Other Threads in the VB.NET Forum
- Previous Thread: grid view problem
- Next Thread: Need help with countdown timer for a poker clock
| Thread Tools | Search this Thread |
.net .net2008 2008 access account advanced application array basic beginner browser button buttons center click code combo cuesent data database datagrid datagridview date datetimepicker designer dissertation dissertations dissertationtopic excel exists fade filter forms generatetags html images input insert intel internet listview map mobile module monitor msaccess net number objects open panel passingparameters pdf picturebox picturebox2 port position print printing problem regex right-to-left save search searchvb.net select serial settings shutdown soap socket sqldatbase sqlserver survey table temperature textbox timer timespan transparency txttoxmlconverter update user usercontol vb vb.net vb.netformclosing()eventpictureboxmessagebox vba vbnet visual visualbasic visualbasic.net visualstudio.net visualstudio2008 web winforms wpf wrapingcode xml year






I have another question. How can i load a form from another form? I tried