I would select everything from the table and use a stream writer to export it to csv
Dim cn As New OleDbConnection
Dim qry As String = "SELECT * FROM YOURTABLE"
Dim myReader As OleDbDataReader
Dim myWriter As New StreamWriter(DIRECTORY AND NAME OF THE FILE)
Try
cn.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & PATH TO YOUR TABLE& ";Persist Security Info=True"
cn.Open()
Using cmd As New OleDbCommand(qry, cn)
myReader = cmd.ExecuteReader()
myWriter.Writeline(ALL YOU HEADERS SEPERATED BY COMMAS)
While myReader.Read()
string line = myReader(FIELD IN YOUR TABLE) +
"," + myReader(FIELD IN YOUR TABLE)
myWriter.Writeline(line)
End While
End Using
myReader.Close()
cn.Close()
Catch ex As Exception
End Try
is this what you meant?