How can we populate a combo box with data from database in 3 tier application in vb.net? please help....
I used this in my client server application. However we now have to convert it to 3 tier application. Can someone please help me. I need to populate the combo box from the data layer.
Private Sub loadStudents()
Dim DBConnection As New MySQLConn
DBConnection.connect()
Dim Query As String
Query= "SELECT StudentID FROM StudentTable"
Dim dreader As OleDbDataReader
dreader = DBConnection.selectQuery(query)
If dreader.HasRows Then
While dreader.Read
cmbStudID.Items.Add(dreader.Item(0))
End While
End If
End Sub
thanks...