Skip to end of metadata
Go to start of metadata

Intro

WordWriter allows you to insert elements from separate documents. You can use this functionality to copy/paste document elements into different files, or to easily merge Word documents. This sample demonstrates how to merge three different Word documents into one unified document.


This sample uses the WordApplication class to open three existing documents and insert them into a new blank document. The InsertBefore() and InsertAfter() methods are used, which accept an element from the current document or any other document, inserting it into the current document.

Code

Download

Files to be Merged:

Output File: MergedDocument_out.doc

  • No labels