Hello Everyone:
I am new in programming and I am using vb2005, I am trying to connect to an MS Access database and I am getting an erro message on the following line of code:
Error:'System.Data.Odbc.OdbcConnection' cannot be converted to 'System.Data.SqlClient.SqlConnection'.Code:searchtable_command = New SqlClient.SqlCommand(searchtable_string, testsearch_connection)
Here my connection string:
What am I missing?Code:Dim testsearch_connection As New Odbc.OdbcConnection("Provider=MSDASQL;Driver={Microsoft Access Driver (*.mdb)};Dbq=C:\CesarAccessdatabase.mdb;Uid=admin;Pwd=;")
Thank you so much for your help
BK




Reply With Quote