TransferSpreadsheet command

P

Pietro

Hi,
I worte the below code to export an access table into excel sheet,first it
was working well,later it gave me an error message"Microsoft jet database
cannot find the object ". make sure the object exists or you've written the
correct path...ecc" and sometimes "Type mismatch"
The code I'm using is:
DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel9, "Annual",
"C:\Documents and Settings\botroswadia\Desktop\Arb-Eng.xls", True, ""

Can anybody help?
 
H

Henry J

Where are you running the code from?

I had a similar error where working code suddenly breaks. I never solved
why it happened. But I was able to get rid of the error by requerying my
form, and the export would work.
 

Ask a Question

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.

Ask a Question

Top