Solved

Can Access 2007 export a report to Word and save it in a 'prior to 2007' format?

Posted on 2010-11-16
6
351 Views
Last Modified: 2012-05-10
I have a command button on an Access 2007 form which exports a report to Word. Is it possible, through VBA, to export the report and have it saved in a format compatible with older versions of Word?
0
Comment
Question by:newbie46
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 77

Expert Comment

by:peter57r
ID: 34145320
If you specify a .doc file that should be sufficient.
0
 
LVL 92

Expert Comment

by:Patrick Matthews
ID: 34145325
Please post the code you are using now.
0
 

Author Comment

by:newbie46
ID: 34145351
matthewspatrick,
DoCmd.OutputTo acOutputReport, "rptA", acFormatRTF, PMTableName & ".rtf", True
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 92

Accepted Solution

by:
Patrick Matthews earned 500 total points
ID: 34145476
Access does not do a native export to Word.  The closest it gets to is RTF (rich text format), which Word is able to interpret.  Some, but by no means all, of the formatting in Access is translatable into RTF, but in my experience the fidelity is not high, and I avoid using it unless I absolutely must.

Have you tried opening an RTF document generated from Access 2007 in Word 2003?  My gut feeling is that it will probably work.
0
 

Author Closing Comment

by:newbie46
ID: 34145663
thanks.
0
 
LVL 48

Expert Comment

by:Dale Fye (Access MVP)
ID: 34145797
Personally, I avoid the RTF export as well, since it embeds hard carrage returns and has other formatting issues.

If I want my output to go to Word, I generally write a custom procedure that opens Word via automation, and I build the Word document from scratch.  I could post some sample code (if you are interested), it wouldn't mean much because all the tables and fields are meaningless, but it might give you some ideas regarding how to do this.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Access custom database properties are useful for storing miscellaneous bits of information in a format that persists through database closing and reopening.  This article shows how to create and use them.
Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
The viewer will learn how to use a discrete random variable to simulate the return on an investment over a period of years, create a Monte Carlo simulation using the discrete random variable, and create a graph to represent the possible returns over…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question