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

Whats the difference between CONCAT and CONCATENATE?
The newer CONCAT function can reference a range of cells. =CONCATENATE(A1,A2,A3,A4,A5) becomes =CONCAT(A1:A5)

Forum statistics

Threads
1,224,823
Messages
6,181,177
Members
453,021
Latest member
Justyna P

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