Export report to Word document

Nadine67

Board Regular
Joined
May 27, 2015
Messages
225
Hello and thank you for any attention my post may receive.

I have a report in my Access db which I would like to export as a DOC or RTF so that images can be pasted to it, rather than import the images in the db which will take up too much room.

I can successfully export the report as both DOC and RTF which is fine however ideally the document fields and formatting need to be protected, except for the two fields where an image will be pasted. Is this possible? Or is there another file format which will achieve my goal. Or is there another solution such as exporting to a template document?

I would also like to save the document to the user's desktop and open upon export.

Thank you and have a great day!
 
Paul I have referenced MS Office 16.0 Word Library and placed this code in the db (attached to a command button)....and added the following, to 'update the document', to your code

Code:
With wdDoc
  'update the document
  .FormFields("EIID").Result = Me!EIID
  'save & close

Paul my field is populating as it should and so I will now add the rest of the fields.

Thank you so very much Paul. I do appreciate you patience and valuable help.

Have a great day Paul!
 
Upvote 0

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.

Forum statistics

Threads
1,223,248
Messages
6,171,027
Members
452,374
Latest member
keccles

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