View Single Post
 
Old 12-05-2013, 10:54 AM
PosseJohn PosseJohn is offline Windows XP Office 2007
Novice
 
Join Date: Jul 2011
Posts: 20
PosseJohn is on a distinguished road
Default How to Open a Word Document from ACCESS VBA

I need help opening a file from a UserForm which has a command button to open a word document.

I am using Access2003 and Word 2010. Some machines are running XP and others WIN7.

I would like the Document to open, have it showing with either macros already enabled or the prompt to enable them.

I was trying the following, but the WIN7 would open the document as read-only with no apparent way to enable the macros.
Code:
 
Webtarget = "\\fileserver\location\unit\ShiftTurnover\U3TO.docm" 'Create an instance of MS Word Set oApp = CreateObject(Class:="Word.Application") oApp.Visible = True 'Open the Document oApp.Documents.Open FileName:=Webtarget
The word file was previously tagged as a trusted site in WIN7.
Reply With Quote