It is a workflow now. It worked fine with Word 2010. Now we are upgrading to Word 2016. It has problem to open the workflow created docx. I cannot figure it out why. So I tried to write code to fill the Word document from a template. I am using DocumentFormat.OpenXml.Wordprocessing to work on the document. I do not know how to fill the fields in the form from the SharePoint item. The following is my code. Many thanks for your help.
↧