Export MS Access query to MS Excel

Agarfey

New Member
Joined
Aug 19, 2002
Messages
3
Hi People,

I currently use the following code to export a MS Access query into MS Word. I would like to know how to achieve the same result. ie Export to Excel in place of Word. Can anyone help.

Private Sub cmdExportWord_Click()
Dim strQueryName As String
strQueryName = "qdf_Export_DA_Objectives"
Call qw_wExportRTF(strQueryName)
End Sub

Thanks
Abe
This message was edited by Agarfey on 2002-09-09 15:25
 

Excel Facts

Shade all formula cells
To shade all formula cells: Home, Find & Select, Formulas to select all formulas. Then apply a light fill color.
It seems a lot of people encounter problems importing/exporting to Access through VB!

Are you wanting to run the procedure from within Access or Excel?

My recommendation would be to set up the macro in Access if you're more comfortable in Access than Excel(DoCmd etc...) and then write a simple Macro in Excel that calls the Access procedure.
 
Upvote 0

Forum statistics

Threads
1,215,006
Messages
6,122,665
Members
449,091
Latest member
peppernaut

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top