Make a Report Editable in Ms Word From Ms Access

  • Thread starter Thread starter Eamon Straughn
  • Start date Start date
E

Eamon Straughn

Hi,
I am currently working on this project for a clients and they would like to
edit the report from access into word. i can get the button to show the
report just cant get the report to then open up word and put the details
from it into word can anyone help me
 
Hi,
I am currently working on this project for a clients and they would like to
edit the report from access into word. i can get the button to show the
report just cant get the report to then open up word and put the details
from it into word can anyone help me

Select the Report, then click
Tools + Office Links + Publish it with Microsoft Word

Or ..... click on the Office Links tool button.
 
this code below is right to my knowledge to open up the report and show the
data for the mailing list. however, i would like to expand this further by
taking the details from the report and then publish it into word by the
click of the button.

this the code i am using to open up the report and show the data. can
someone please help me expand it to my desired result.

Private Sub cmdGo_Click()
Dim stDocName As String
Dim qry As DAO.QueryDef
Dim cy As Page

DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70

Call SetGlobal("ReportMailingID", "", Me.ID)

stDocName = "rMailing1"
DoCmd.OpenReport stDocName, acPreview
DoCmd.RunCommand acCmdCompleteWord


End Sub
 
this code below is right to my knowledge to open up the report and show the
data for the mailing list. however, i would like to expand this further by
taking the details from the report and then publish it into word by the
click of the button.

this the code i am using to open up the report and show the data. can
someone please help me expand it to my desired result.

Private Sub cmdGo_Click()
Dim stDocName As String
Dim qry As DAO.QueryDef
Dim cy As Page

DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70

Call SetGlobal("ReportMailingID", "", Me.ID)

stDocName = "rMailing1"
DoCmd.OpenReport stDocName, acPreview
DoCmd.RunCommand acCmdCompleteWord

End Sub

I think this is all you need:

Private Sub cmdGo_Click()

' Save the new record
DoCmd.RunCommand acCmdSaveRecord

' Output the report to a document and open the document.
DoCmd.OutputTo acOutputReport, "rMailing1", acFormatRTF, "Path and
File name here.rtf", True

End Sub

If you don't enter the Path and File name, you will be prompted with a
file navigation box to select the folder and name.
The True argument opens the document window.

See VBA help on the OutputTo method for the other acFormats you can
use.

I have no idea what you are doing with rest of the stuff in your Code.
 
Back
Top