Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Opening Microsoft Word in VB.Net

Status
Not open for further replies.

tassflint

Programmer
Dec 29, 2005
21
US
Hello all,

I created a document using VSTO and have it working perfectly. What I am wanting to do is call microsoft word from within another vb.net application and once word opens, have it run the document. Does anyone know how this can be accomplished?



Thanks in advance,

Brian
 
Add a reference to Microsoft Word Object Library.
Code:
Import Microsoft.Office.Core

Dim wApp As New Word.Application
Dim cDoc As New Word.Document
cDoc = wApp.Documents.Open("C:\SomeFile.doc")

Sharing the best from my side...

--Prashant--
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top