BoldSignEasily embed eSignatures in your .NET applications. Free sandbox with native SDK available.
WordDocument document = new WordDocument(filename);
string[] fieldNames = new string[] { "Emp_Id", "Name", "Phone", "City" };
string[] fieldValues = new string[] { "1001", "Peter", "+122-2222222", "London" };
//Performs the mail merge.
document.MailMerge.Execute(fieldNames, fieldValues);
//Saves and closes the WordDocument instance
document.Save("Sample.docx", FormatType.Docx);
document.Close();
I'm getting a NullReferenceException at the "Execute" statement (StackTrace: "at Syncfusion.DocIO.DLS.WField.UpdateFieldRange()"). Is there a bug or am I doing something wrong?
Best wishes
Gernot
Hi Gernot,
We have created a support incident for the reported Null reference exception issue while performing mail merge using DocIO under your account. Please log on to our support website to check for further updates
https://www.syncfusion.com/account/login?ReturnUrl=%2fsupport%2fdirecttrac%2fincidents
Regards,
Sarath