Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Using conn = New OleDbConnection(connstring)
- Try
- Dim Sql As String = "SELECT * FROM Products WHERE [Product Name] LIKE '" & txtSearchProduct.Text & "*'"
- Dim da As New OleDbDataAdapter(Sql, conn)
- Dim ds As New DataSet
- da.Fill(ds)
- DataGridView2.DataSource = ds.Tables(0)
- Catch ex As Exception
- MsgBox(ex.ToString, MsgBoxStyle.OkOnly Or MsgBoxStyle.Exclamation, "Error")
- End Try
- End Using
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement