Full Version: Export To Excel And Create Sum In Excel
UtterAccess Discussion Forums > Microsoft® Access > Access Automation
Thor
Hi all,

i am using this code to export the query result to Excel. The spreadsheet opens and i elaborate the data in excel.

The query includes numeric values in the field “Amount”. How to i extend below code to also include the SUM for the column “Amount”.

Private Sub Excelexport_Click()
DoCmd.OutputTo acQuery, "AmountReportQuery", "MicrosoftExcel(*.xls)", "c:\MyReports\Amountreport.xls", True, ""

End Sub


I took a look at Mr Bob Larsson's excellent example..but i cannot identify anything in that code solving my question..

Thanks!
Bob G
can you post the SQL view of your underlying query that you are exporting ?
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.