I am converting a VB6 project to C# and I need to get the Active word document object. In vb6 it is easy by using
dim objWordDoc as Word.Document
set objWordDoc = Word.ActiveDocument
I need to get the Word's active word document using C#. I have added the below references to the project
And added the references to the class as
using Word = Microsoft.Office.Interop.Word;
using Office = Microsoft.Office.Core;
Private Word.Document _activeDocument;
Is there any function like in C# to get the active word document?
_activeDocument = Word.Application.ActiveDocument;