如何使用C#在MS Word 2007(docx文件)中以编程方式读取包对象 [英] How to read package object programatically in MS word 2007 (docx file) using c#
本文介绍了如何使用C#在MS Word 2007(docx文件)中以编程方式读取包对象的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在尝试使用c#读取嵌入在MS Word 2007 docx文件中的Package对象.我想读取包对象中的内容(可以是ppt,excel或图像).目前,我在package对象中只有一个文件.
预先感谢您的帮助.
Hi,
I am tring to read an Package object embedded in an MS word 2007 docx file using c#. I want to read the content(Can be an ppt,excel or an image) inside the package object. Currently I have just one file inside the package object.
Thanks in advance for any help.
推荐答案
docx文件只是zip中的XML,因此,知道了,您应该能够通过重命名来确定格式将该文件保存为.zip并进行浏览. J#可以解压缩,其中包含dll的文章可在C#中使用来解压缩文件.
A docx file is just XML in a zip, so, knowing that, you should be able to work out the format by renaming the file to .zip and exploring it. J# had the ability to unzip, there''s articles with dlls you can use in C# to unzip a file.
这篇关于如何使用C#在MS Word 2007(docx文件)中以编程方式读取包对象的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文