以编程方式或第三方工具将 Office 文档转换为 XPS 文件
我正在开发一个应用程序,它实际上需要在预览窗格中进行文件预览,因此在谷歌上进行大量搜索后发现,有一些方法可以使用 PreviewHandlers 实际预览文件,但管理层不希望这样做一个解决方案。
因此,如果没有它,我们只能将文档转换为 XPS 并使用它们在 DocumentViewer 中预览,其中所有工具都可用。
对于 PDF 文件,Acrobat 提供了一个很好的 COM 组件。这里的问题是我能够将 doc、docx 文件转换为 xps 以将它们显示为预览,但无法将任何其他文件转换为 xps。
或者一个将所有文件转换为 pdf 的库也可以。
如果有人以前遇到过这个问题或者知道解决方案/第三方库可以转换文档,那么我们非常感谢您的帮助。
谢谢
I have an application that i am working on which needs actually a file preview in a preview pane so because of that after searching a lot on google found that there are some ways to actually preview the files using PreviewHandlers but management does not want that to be a solution.
So without that we can only be left with converting the documents to XPS and use them to preview in DocumentViewer where all the tools are available.
For PDF file Acrobat provides a COM component that is fine. The problem here is i am able to convert doc,docx files to xps to show them as preview but not able to convert anyother files to xps.
Or a library that converts all files to pdf that also is fine.
if someone has faced this before or know the solution/Third party library that does the work to convert the documents then the help is really appreciated.
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
尝试 Microsoft 2007 Microsoft Office 加载项:Microsoft 另存为 PDF或 XPS。查看 这个示例
Try Microsoft 2007 Microsoft Office Add-in: Microsoft Save as PDF or XPS. Chect out this example