Is that supposed to be the name of the table or query in your database
that you wish to export?
Then put it within quotes (it's supposed to be a string).
If that is not the name of the table, but a variable, then:
Dim excel as string
excel = "The Name of Table or Query"
DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel9, excel,
"C:\PRSPREADSHEETS\jobs.xls"
Then your code should work without quotes around excel.
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.