public void WordTestWithTemplateTable() { MyWordWithTemplate myWordWithTemplate = new MyWordWithTemplate(@"D:\User\lufangtao\G-大洋调查现场使用样品登记表.doc", @"D:\User\lufangtao\WordTestWithTemplateTable1.doc"); myWordWithTemplate.CreateWord(); myWordWithTemplate.OpenWordTemplate(); myWordWithTemplate.CopyAndPasteTemplateTable(); Dictionary<string, string> replaceLabel = new Dictionary<string, string>(); replaceLabel["RequistionNum"] = "1001"; myWordWithTemplate.ReplaceLabel(replaceLabel); myWordWithTemplate.SaveTemplateWord(); }
public void WordTestWithTemplateTable() { MyWordWithTemplate myWordWithTemplate = new MyWordWithTemplate(@"D:\User\lufangtao\G-大洋调查现场使用样品登记表.doc", @"D:\User\lufangtao\WordTestWithTemplateTable1.doc"); myWordWithTemplate.CreateWord(); myWordWithTemplate.OpenWordTemplate(); myWordWithTemplate.CopyAndPasteTemplateTable(); Dictionary <string, string> replaceLabel = new Dictionary <string, string>(); replaceLabel["RequistionNum"] = "1001"; myWordWithTemplate.ReplaceLabel(replaceLabel); myWordWithTemplate.SaveTemplateWord(); }