I know there are heaps and heaps of threads out there on recommending and using OpenXML to manipulate a Word 2007 (docx) document.
But none I could find, have a practical example (full solution in zip) that I am able to try out and demonstrate to learn quickly how to use OpenXML. What I am after is a way to open a Word 2007 document template with several mailmerge fields, populate those fields from a dataset (SQL Server 2005) and save the template as a Word document ready to email.
And please do not recommend 3rd party products as we have to look for a free workable solution.
Much appreciate your time. Thanks
Here's an example.
It uses docx4j.NET - which is open source and which you can get from Nuget - not Microsoft's Open XML SDK.