M
microsoft
Hi
I am trying to export data from access to excel. I have used the following
code.
Private Sub Export_Click()
On Error GoTo Err_Export_Click
Dim stDocName As String
stDocName = "Trade Ticket"
DoCmd.OutputTo acReport, stDocName
Exit_Export_Click:
Exit Sub
Err_Export_Click:
MsgBox Err.Description
Resume Exit_Export_Click
End Sub
Trade ticket is the name of the report.
The export is pulling all the fields from the report into Excel. Is it
possible to have only certain fields exported from the report to the excel
document. Also is it possible to set the order in which the fields are
exported.
Thanks for any assistance in advance.
I am trying to export data from access to excel. I have used the following
code.
Private Sub Export_Click()
On Error GoTo Err_Export_Click
Dim stDocName As String
stDocName = "Trade Ticket"
DoCmd.OutputTo acReport, stDocName
Exit_Export_Click:
Exit Sub
Err_Export_Click:
MsgBox Err.Description
Resume Exit_Export_Click
End Sub
Trade ticket is the name of the report.
The export is pulling all the fields from the report into Excel. Is it
possible to have only certain fields exported from the report to the excel
document. Also is it possible to set the order in which the fields are
exported.
Thanks for any assistance in advance.