kipster1203
Registered User.
- Local time
- Today, 06:27
- Joined
- May 5, 2010
- Messages
- 13
This might be a tricky question, but I thought maybe someone out there might know how to do this.
So the way my program works is it creates an excel file with multiple tabs, and where each tab contains columns of data with a graph of that data next to it.
Now what I would love to do would be to be able to print those graphs after the excel file has opened, or even when that function is called. The excel doesnt even really have to open, that's just the way I have it now so we can print manually. Here is the end of code:
So the way my program works is it creates an excel file with multiple tabs, and where each tab contains columns of data with a graph of that data next to it.
Now what I would love to do would be to be able to print those graphs after the excel file has opened, or even when that function is called. The excel doesnt even really have to open, that's just the way I have it now so we can print manually. Here is the end of code:
Code:
.
.
.
DoCmd.TransferSpreadsheet acExport, , "Document Delivery Temp Table", "W:\edsplus\applications\0cmad\cmad_chart_spreadsheet.xls", True, "Document_Delivery_Data"
DoCmd.TransferSpreadsheet acExport, , "Average Temp Table", "W:\edsplus\applications\0cmad\cmad_chart_spreadsheet.xls", True, "Document_Delivery_Sum_Average"
DoCmd.OpenQuery ("Delete Document Delivery Temp Table Query")
DoCmd.OpenQuery ("Delete Average Temp Table Query")
Else
End If
' Create a new Excel instance
Set oXL = CreateObject("Excel.Application")
' Full path of excel file to open
sFullPath = "W:\edsplus\applications\0cmad\cmad_chart_spreadsheet.xls"
' Open it
With oXL
.Visible = True
.Workbooks.Open (sFullPath)
End With
DoCmd.SetWarnings True
Exit_Generate_Chart_Request_Click:
Exit Sub
Err_Generate_Chart_Request_Click:
MsgBox Err.Description
Resume Exit_Generate_Chart_Request_Click
End Sub