Solved

Export Access 2007 Query to Excel 2007+

Posted on 2013-01-11
2
940 Views
Last Modified: 2013-01-11
Hi,

I am trying to export the results of a query to excel so that i can use the excel sheet on my tablet pc.

However, when the excel sheet is saved to my pc it is in "2003-2007" format and this is not compatible with my tabet pc.

I need to change my code (below) so that the excel file is in a later format than 2003-2007.

Can anyone help please?

DoCmd.OutputTo acOutputQuery, "MSSL Customer Details", "Excel97-Excel2003Workbook(*.xls)", "", True, "", 0, acExportQualityPrint

I have also tried the following code but this is no good either:

DoCmd.OutputTo acQuery, "MSSL Customer Details", "MicrosoftExcel(*.xlsx)", "", False, ""

Many thanks
0
Comment
Question by:andrewpiconnect
2 Comments
 
LVL 119

Accepted Solution

by:
Rey Obrero earned 500 total points
ID: 38767426
try using



DoCmd.OutputTo acOutputQuery, "MSSL Customer Details", "Excel Workbook(*.xlsx)", "", True, "", 0, acExportQualityPrint
0
 

Author Closing Comment

by:andrewpiconnect
ID: 38767642
works a treat....many thanks
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In Debugging – Part 1, you learned the basics of the debugging process. You learned how to avoid bugs, as well as how to utilize the Immediate window in the debugging process. This article takes things to the next level by showing you how you can us…
Describes a method of obtaining an object variable to an already running instance of Microsoft Access so that it can be controlled via automation.
In Microsoft Access, learn how to use Dlookup and other domain aggregate functions and one method of specifying a string value within a string. Specify the first argument, which is the expression to be returned: Specify the second argument, which …
With Microsoft Access, learn how to start a database in different ways and produce different start-up actions allowing you to use a single database to perform multiple tasks. Specify a start-up form through options: Specify an Autoexec macro: Us…

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now