Open Word file by Macro

S

Shazi

Hi,

I prepared a menubar, and I am unable to open all excel files by
macro.

I want to open Word Document by Excel Macro. how to open word file.

Regards.

Shahzad
 
M

Mike H

try

Sub OpenDoc()
Dim WordApp As Object
Set WordApp = CreateObject("Word.Application")
WordApp.documents.Open "C:\test.doc" 'Change to suit
WordApp.Visible = True
End Sub

Mike
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top