Quantcast
Channel: .NET Framework Class Libraries forum
Viewing all articles
Browse latest Browse all 8156

Selecting Office version To Open Word Document

$
0
0

Dear All,

I am coding a simple application that opens a word document a windows form application.

The code is simple:

(Reference has been added to Microsoft.Office.Interop.Word version 12.0)

Public Sub Load()

Dim    ObjWord as   Word.Application

try

  ObjWord = New Word.Application

  ObjWord.Documents.Add()

  ObjWord.Visible = True

catch ex as exception

Finally

end try

End Sub

My problem is the following :

I have both versions of office installed : 2007 and 2010, I need a way to make word open in any of the versions ( it is actually opening in 2010 format).

Your help is much appreciated.


Viewing all articles
Browse latest Browse all 8156


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>