I am trying to select all the data in my datatable using a sql statement but I am having trouble. I then export the datatable to a dbf file. Here is what I have so far:
Code:Dim dBaseConnection As New System.Data.OleDb.OleDbConnection(“Provider=Microsoft.Jet.OLEDB.4.0;” & “Data Source=” & path & “;” & “Extended Properties=dBase IV”) dBaseConnection.Open() Dim SQLCreateCommand As String Dim NewString As String = dt.ToString SQLCreateCommand = "SELECT * INTO NewTable From " & DataTable Dim dBaseCommand As New System.Data.OleDb.OleDbCommand(SQLCreateCommand, dBaseConnection) dBaseCommand.ExecuteNonQuery() dBaseConnection.Close()




Reply With Quote
