Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.
inserting datareader objects into an arraylist...
I have a question, How do i insert values from an sql server column into an arraylist? So far i have been trying the sqldatareader, but have problems.
I have made all the connections, and they are working fine. The problem i am having is storing the strings in the arraylist 1 by 1(most likely using the while loop), to be able to retrieve them later in the page. I am using vb.net/asp.net.some of the code is posted below:
Dim myUserSql As String = "Select username from Customer"
Dim myCmd As New SqlCommand(myUserSql, dbconn)
Dim myreader As SqlClient.SqlDataReader
myreader = myCmd.ExecuteReader
The purpose of the project is to store usernames in an arraylist, to be checked against the input from the user when they input into the appropriate field.
0 · ·