Good Day,
I am trying to open up a word file via Excel VBA and am encountering a problem I've not before. Looking for some assistance.
Here is my code:
Private Sub CommandButton1_Click()
Workbooks.Open "P:\test.docx", ReadOnly:=True
End Sub
It seems to be a pretty simple code and I currently use the same code in other Macros to open other Excel files, however, this is my first for trying to open a word document.
The error I am receiving is "Run-time error '1004': Test.docx: file format is not valid."
This is a brand new file I've created just for testing purposes.
Thoughts?
Bookmarks