Example #1
0
 public void CanCreateCorrectThemisDocument()
 {
     using var doc = WordprocessingDocument.Open(new MemoryStream(Resources.template_themis_docx), true);
     OpenXmlWordProcessing.SetContentControlContent(doc, "txt1", "SetContentControlContent");
     OpenXmlWordProcessing.SetContentControlContent(doc, "txt2", "ProcessRepeatingSection");
     OpenXmlWordProcessing.ProcessRepeatingSection(doc, "TablePercentage",
                                                   new Dictionary <string, IEnumerable <string> >()
     {
         { "MnthOrd", new List <string> {
               "1os", "2os", "3os"
           } },
         { "Prcntge", new List <string> {
               "10%", "20%", "30%"
           } },
     });
     doc.SaveAs(@".\__document_themis.docx");
 }