C#替换文本字符串中的docx
问题描述:
使用C#,有没有好办法来查找和替换在的docx文件中的文本字符串,而无需安装在机器上的字?
Using C#, is there a good way to find and replace a text string in a docx file without having word installed on that machine?
答
是,使用的Open XML 。这里是既解决您的具体问题的文章:创建一个简单的搜索和替换Word 2007的Open XML格式文档
Yes, using Open XML. Here's an article which addresses your specific question: Creating a Simple Search and Replace Utility for Word 2007 Open XML Format Documents