access data linked to a word document

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Does any one have any ideas how I can get data from access to a word document
that can be linked, so that if the source data canges the word document is
updated as well.

The database containes transaction for a general leger and the word document
will be a set of Financial statements i.e. income , balancs sheet and notes
to statements.
Most of the doucment will have wordey bits but the data would come from the
database.
Thanks
Danny
 
You can use book marks in word to transfer data from Access to Word.
Create A word document, insert book marks where you want the value from
access should be displayed, and then run this code

Public Sub PrintToWord()
Dim wd As Word.Application
Dim myDoc As Word.Document

Set wd = New Word.Application
wd.Documents.Add DOTpath & reportName & ".dot" ' The name and path
Set myDoc = wd.ActiveDocument
With wd.Selection
.GoTo wdGoToBookmark, Name:=BookMarkName ' The name of the book
mark
.Font.Bold = True ' You can choose if bold
.Font.Underline = False ' or underline
.TypeText Text:=ValueToInsertInTheBookMark ' insert values
End With
wd.Visible = True

End Sub

You need to create reference to Microsoft Word
 
Back
Top