[mso] ACCESS 2002: Export Table To Excel Problems

Using Access 2002 on XP operating system.  Have problems with exporting a
table to excel.  Using below to automatically make, then export a table to
excel.  The problems are:
1. Export to excel process seems to take an extremely long time, especially
it is exporting a small table, not re-running a query.
2. Once excel file is created, can't open it in excel.  Says file can't be
found, even when you click on it.

Tested the process by going directly to the table and right click/export
from there.  The export processes instantly and excel is able to open the
file.  The below code was only to make it easier to the user so they didn't
have to press F11 to open the database/table view, then scroll to their
table, then right click/export.  However, something is not happening
correctly in the process that utilizes code on the form click button vs
exporting directly from the table.

Is the problem with my code or just the process itself in Access, and
Access does not handle this automated process well?  Open to any
suggestions, it's not critical since the user always has the step to do
above manual process, so we're still operational.  I am just wanting to
automate the process should other users need to be involved and to just
plain eliminate the manual processes.  Thank you!

Private Sub Export_Click()
    MsgBox "Please wait while the CL Export runs . . . thank you!"
    DoCmd.SetWarnings False
    DoCmd.OpenQuery "qmak_CL_Export", acViewNormal, acEdit
    DoCmd.OutputTo acTable, "MM_CL", "MicrosoftExcelBiff8(*.xls)", "",
True, "", 0
    DoCmd.SetWarnings True
End Sub




-----------------------------------------------------------------------------------------------------
The information transmitted is intended only for the person
or entity to which it is addressed and may contain confidential
and/or privileged material. If you are not the intended recipient 
of this message you are hereby notified that any use, review,
retransmission, dissemination, distribution, reproduction or any
action taken in reliance upon this message is prohibited. If you 
received this in error, please contact the sender and delete the 
material from any computer.  Any views expressed in this message
are those of the individual sender and may not necessarily reflect 
the views of the company.  
-------------------------------------------------------------------------------------------------------

*************************************************************
You are receiving this mail because you subscribed to mso@xxxxxxxxxxxxx or 
MicrosoftOffice@xxxxxxxxxxxxxxxx

To send mail to the group, simply address it to mso@xxxxxxxxxxxxx

To Unsubscribe from this group, send an email to 
mso-request@xxxxxxxxxxxxx with the word "unsubscribe" (without the quotes) in 
the subject line.

Or, visit the group's homepage and use the dropdown menu.  This will also allow 
you to change your email settings to digest or vacation (no mail).
http://www.freelists.org/webpage/mso

To be able to use the files section for sharing files with the group, send a 
request to mso-moderators@xxxxxxxxxxxxx and you will be sent an invitation with 
instructions.  Once you are a member of the files group, you can go here to 
upload/download files:
http://www.smartgroups.com/vault/msofiles
*************************************************************

Other related posts: