Author: cm2282 | Posted on: 7/29/2010 12:44:09 PM | Views : 281

hi,
It is possible to have each value of a listboxes inserted into a SQL database in a different datafield? For example, if I have a list box of Newark, Chicago, Atlanta, NYC, and Miami. The values are the same. I would like Chicago to go into the datafield saying chicago and so on.
Is the following way the correct form to loop through a listbox to retrieve selected items toinsert it into the database?
Dim i As Integer
For i = 0 To ListBox1.Items.Count - 1
If ListBox1.Items.Item(i).Selected = True Then
Response.Write(ListBox1.Items.Item(i).Value)
End If
Next
Thanks,
Carlos
 
...

Go to the complete details ...