|
Here is a post I found on CramSession
Can you guys make this work with Kix?
Export From Access to HTML
"Export data from Access to .txt, .htm, .xls, etc., using Visual Basic"
Visual Basic, Jerry@AppDC.com Try this out to export from an Access database to a text, htm, xls, etc. file. Export a table or a stored query. '---------------------- Dim sSQL As String Dim sFileType As String Dim sDestPath As String Dim sExt As String Dim sTableQuery As String
sFileType = "Text;" sExt = "txt" sDestPath = "C:\Temp\" sTableQuery = "tCustomers"
sSQL = "SELECT * INTO [" & sFileType & _ "DATABASE=" & sDestPath & "].[FileName" & _ sExt & "] " & "FROM [" & sTableQuery & "]"
DB.Execute sSQL, dbFailOnError
'------------- Try these out too: sFileType = "HTML Export;" sExt = "htm" '--- sFileType = ""Excel 4.0;" sExt = "xls" '---Also: "dBase III;" "dBase IV;" "dBase 5.0;" "Lotus WK1;" '--- I'm still trying to get it to work using parameterized stored queries...
|