I have a .vbs script that I'm running from the Windows destkop (intend
to have it run by Windows' task scheduler) to pull an export from MS
Access. Here's the script:
' **************************
dim objAccess
Set objAccess = CreateObject("Access.Application")
ObjAccess.OpenCurrentDatabase("C:\codescratch\db1. mdb")
ObjAccess.DoCmd.TransferText acExportDelim, "Expout Export
Specification","table1", "C:\expout.txt", False, ""
ObjAccess.CloseCurrentDatabase
Set ObjAccess = Nothing
MsgBox "Script has finished running."
' **************************
....in this code, "Expout Export Specification" is an export spec I
defined in Access for this simple, 3-col. test table. Using it to
export from within Access works fine.
I get no errors in this script, but the output file is not updates
when this is run. No write to that file takes place. I am required
to have some kind of file present on the filesystem at, in this case,
C:\expout.txt or the script complains that it can't find the file.
That seems odd to me. But again, the file is not updated.
What am I doing wrong? Thanks!
bp