SendObject in MSAccess XP

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I was able to use SendObject in Access '97. Having installed XP Pro and
converted my database to Access XP, I can no longer email queries.

I get:- "error code 2281: The formats that enable you to output data in
Excel format are missing or incorrectly registered in the Windows Registry"
Can anyone tell me how to solve this please?

Thanks
 
Can you use the File|Export menu command to export the query to Excel?
If not, try the following:

If the import/export wizards don't work at all, re-register ACCWIZ.DLL

If it's one or more file formats that aren't listed, re-register the
following files
msexcl40.dll (Excel)
msxbse40.dll (dBase)
mspdox40.dll (Paradox)
mstext40.dll (Text, CSV, tab-delimited))
In Access 97, the filenames contain 35 instead of 40.

To re-register a DLL file,

1) Locate it (usually all these are in the Windows\System32 or
WINNT\System32 folder.

2) Locate the file regsvr32.exe.

3) Drag the DLL file's icon onto the regsvr32.exe icon.
 
G'day John. Thank you for your much appreciated reply. Are you certain that
ACCWIX.dll is correct. I doubled-clicked on it and it wanted to check the
size of type I could read, so I did not persist.

I have dragged msexcl40.dll and mstext40.dll onto regsvr32.exe. Each one was
handled correctly according to the prompt I received.

I can use File|Export to save a table or a query as an Excel spreadsheet. I
cannot save either as a .csv file. I am told that I attempted an illegal
operation. It appears that msexcl40.dll has been correctly installed but
mstext40.dll is not working.

If I execute the following line of code:-
DoCmd.SendObject acSendQuery, "qryConstants", acFormatXLS, "Terry McCrea", ,
, "Constants Query Test", , False

I get the same as original error code 2281.

I would appreciate some more ideas, please.
Regards, Terry McCrea
 
Hi Terry,

I never use SendObject myself and don't know the problems it has, but
thought that re-registering the DLLs might fix it (and wouldn't do any
harm). But if you can't export to a text file after re-registering
MSTEXT40.DLL there's something wrong with your installation beyond my
experience (by the way, you say you can't export to a CSV file: what
about other text-file formats, such as tab-delimited?).

It might be worth checking out Tony Toews's email page at
http://www.granite.ab.ca/access/email.htm. There's some stuff about
SendObject there. Also, if you haven't already done so, search the
Microsoft Knowledgebase at http://support.microsoft.com, and search
http://groups.google.com for posts that mention SendObject error 2281.

Good luck, and post to a new thread in this newsgroup if you're still
stuck.
 
Back
Top