Developing an application in C# that requires combining multiple Word files? Wordize for .NET is a reliable, professional solution that enables C# developers to efficiently integrate Word file merging functionality.
Practical Word file merging tasks are diverse and include generating consolidated reports in standardized formats and creating complete documents from Word fragments.
The API is designed following C# programming best practices. No external dependencies and seamless integration allow you to quickly implement Word merging functionality into existing .NET projects without architectural changes.
Test the C# API for Word file merging using the online demonstration on this page. Upload several Word files through the form, examine the C# code example, execute the Word merging operation, and download the result for verification.
using Wordize.Merging;
Merger.Merge("Output.docx",
[
"Input1.docx",
"Input2.docx"
]);
using Wordize.Merging;
Merger.Merge("Output.docx",
[
"Input1.docx",
"Input2.docx"
]);
using Wordize.Merging;
using Wordize.Saving;
var imageStreams = Merger.MergeToImages(
["Input1.docx", "Input2.docx"],
new ImageSaveOptions(SaveFormat.Docx) { PageLayout = MultiPageLayout.Vertical(10) },
MergeFormatMode.KeepSourceFormatting
);
using var file = File.Create($"Output.docx");
imageStreams[0].Position = 0;
imageStreams[0].CopyTo(file);
using Wordize.Merging;
using Wordize.Saving;
ImageSaveOptions saveOptions = new ImageSaveOptions(saveFormat);
saveOptions.PageLayout = MultiPageLayout.Vertical(10);
Merger.Create()
.From("Input1.docx")
.From("Input2.docx")
.To("Output.docx", saveOptions)
.Execute();
using Wordize.Merging;
Merger.Create()
.From("Input1.docx")
.From("Input2.docx")
.To("Output.docx", SaveFormat.Docx)
.Execute();