Dim ConnectionString As String = ""
ConnectionString = "Driver={Microsoft Paradox Driver (*.db )};DriverID=538;Fil=Paradox 5.X;DefaultDir=C:\MY_DB;Dbq=C:\MY_DB;CollatingSequence=ASCII;"
Dim ParadoxConn As New System.Data.Odbc.OdbcConnection(ConnectionString)
ParadoxConn.Open()
Dim da As New System.Data.Odbc.OdbcDataAdapter("Select * from my_table", ParadoxConn)
Dim ds As New DataSet
da.Fill(ds, "ParadoxTable")
ParadoxConn.Close()
DataGridView1.DataSource = ds.Tables(0)
沒有留言:
張貼留言