Problems Exporting a table

M

merry_fay

Hi,

I'm trying to export a table from my database into an excel spreadsheet, but
it keeps saying it can't find the object 'ExportData'. It definitely exists &
the rest of my code is quite happy to use it, so I'm really confused as to
what I'm doing wrong!

This is the code:

DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel9, "ExportData",
"H:\Miranda\Fred.xls"

Any ideas/suggestions?

Thanks
merry_fay
 
Top