End With' construct is 'Using' or a Var declaration. In C# I believe the equivalent of a VBA 'With. }Since I'm not sure of the C# syntax, I'm attaching a document with some VBA code to demonstrate how you can populate between the paragraphs by using a bookmark. Var Dest=oWordDoc.Bookmarks("BookmarkName").Range ĭest.InsertAfter ĭest.InsertAfter .Text Using oWordDoc.Bookmarks("BookmarkName").Range }I'm tying to look for an answer for a long time with no success. OWord.Quit(ref oMissing, ref oMissing, ref oMissing) OWordDoc.Close(False, ref oMissing, ref oMissing) Object oSaveAsFile = oSaveAsFile, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing)
0 Comments
Leave a Reply. |