# Re: 如何用vb 去启动office中的word

Posted by Chennet on July 16, 1999 at 01:50:20:

In Reply to: 如何用vb 去启动office中的word posted by yuanann on July 15, 1999 at 23:28:34:

Option Explicit
Private wordapp As Object
Private wordDoc As Document

Private Sub cmd_Click()

Set wordapp = CreateObject("Word.Application")
Set wordDoc = Documents.Open("c:\test.doc")
wordapp.visible = True
set wordapp = Nothing
set wordDoc = Nothing

End Sub

Follow Ups: