Allow to select title from comboBox then display for the select title
Hi..
I have one problem...
how to allow the user to select title from comboBox then display acording for the select title to the textbox...
I read that need to create two data Adapters...
I configure one with the SQl statement:
Select TItle, Author, ISBN FROM Books
WHERE Title = ?
But how to configure the other data adapter?
When i run with only one data Adapter, i get the error:
An unhandled exception of type 'System.Data.OleDb.OleDbException' occurred in system.data.dll
The error point to the code below Private Sub frmBooks_load(....
......dbRnR.Fill(DsBooks1) =error
Thanks
Allow to select title from comboBox then display for the select title
Thanks...
But i used OleDbConnection to connect not SqlConnection..
and i used the data Adapter wizard to edit th SQL code...
is it still the same code to use ?....
This is the code i write into...
Code:
Private Sub frmBooks_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
'dbRnR.Fill(DsBooks1) 'error pointed when running
DisplayRecordPosition()
End Sub
Private Sub cboTitle_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cboTitles.SelectedIndexChanged
DsBooks1.Clear()
dbRnR.SelectCommand.Parameters("Title").Value = cboTitles.Text
dbRnR.Fill(DsBooks1)
End Sub