Quote:Document .Net 5.5.4.14 trial. Have questions? Email us: support@sautinsoft.com
public static void MailMergeSimpleEnvelope() { string templatePath = @"..\..\envelope-template.docx"; string resultPath = "Simpson-family.docx"; DocumentCore dc = DocumentCore.Load(templatePath); var dataSource = new[] { new { Name = "Homer", FamilyName = "Simpson" }, new { Name = "Marge ", FamilyName = "Simpson" }, new { Name = "Bart", FamilyName = "Simpson" }, new { Name = "Lisa", FamilyName = "Simpson" }, new { Name = "Maggie", FamilyName = "Simpson" }}; dc.MailMerge.Execute(dataSource); dc.Save(resultPath); // Open the result for demonstration purposes. System.Diagnostics.Process.Start(new System.Diagnostics.ProcessStartInfo(resultPath) { UseShellExecute = true }); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)