Sub test()
Dim wdApp As Object
Dim wdDoc As Object
On Error Resume Next
Set wdApp = GetObject(, "Word.Application")
If Err.Number <> 0 Then
Err.Clear
Set wdApp = CreateObject("Word.Application")
If Err.Number <> 0 Then
MsgBox "Unable to open Word!", vbExclamation
Exit Sub
End If
End If
On Error GoTo 0
On Error Resume Next
Set wdDoc = wdApp.documents.Open("c:\users\domenic\desktop\doc1.docx")
If wdDoc Is Nothing Then
MsgBox "Unable to open Word document!", vbExclamation
Exit Sub
End If
On Error GoTo 0
'Make Word visible
wdApp.Visible = True
'etc
'
'
'Release objects from memory
Set wdDoc = Nothing
Set wdApp = Nothing
End Sub