T
tjmax
I am using a Access list box to selecdt first a group then select a word
merged document. The code is as follows where strDocName is the full path &
name for the Word mail merge document.
Sub OpenWordDoc(strDocName As String)
'Opens word document selected in frmExportInfo
Dim objApp As Object
'Opens the document
Set objApp = CreateObject("Word.Application")
objApp.Visible = True
objApp.Documents.Open strDocName
End Sub
The Word document opens OK but doesn't update to the selected group (which
update a table than the Word merged document is based on). If I open Word
then open the same mail merge document it update correctly. But it first ask
me if I want to run query that links to the updated Access table - I don't
get this message if I when I open this Word doc from Access.
merged document. The code is as follows where strDocName is the full path &
name for the Word mail merge document.
Sub OpenWordDoc(strDocName As String)
'Opens word document selected in frmExportInfo
Dim objApp As Object
'Opens the document
Set objApp = CreateObject("Word.Application")
objApp.Visible = True
objApp.Documents.Open strDocName
End Sub
The Word document opens OK but doesn't update to the selected group (which
update a table than the Word merged document is based on). If I open Word
then open the same mail merge document it update correctly. But it first ask
me if I want to run query that links to the updated Access table - I don't
get this message if I when I open this Word doc from Access.