如何通过浏览器查看office文档 [英] How to view office document through browser

查看:80
本文介绍了如何通过浏览器查看office文档的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述





i希望开发查看任何办公文档的asp应用程序

我使用

Hi

i want to develop asp application that view the any office document
and i used

Response.ContentType

显示文件



这是代码

to display the document

and this is the code

if (URL.Contains(".doc"))//URL is document path
                  Response.ContentType = "application/msword";
        Response.WriteFile(URL);
        Response.Flush();
        Response.Close();





但是当我跑步时,显示下载的对话框和没看到任何东西



MIMI清单



http://blogs.msdn.com/b/vsofficedeveloper/archive/ 2008/05/08 / office-2007-open-xml-mime-types.aspx
[ ^ ]



any想在浏览器中显示文档,我需要它



Thx



but when i run , display a downloaded dialog and didn''t view any thing

the MIMI list

http://blogs.msdn.com/b/vsofficedeveloper/archive/2008/05/08/office-2007-open-xml-mime-types.aspx
[^]

any idea to display document in browser , i need it necessary

Thx

推荐答案

你无法显示doc文件在浏览器中没有保存它,如果你想,那么你必须为每个浏览器编写插件,这是一个非常长的工作代码。可以在浏览器中打开PDF,如果您可以将doc转换为pdf,这可能是一个简单的解决方案。

祝你好运
You cannot display doc file in browser without saving it, if you want then you have to write plugin with respect to each browser and that is a very length code of work. A PDF can be opened in a browser, if you can convert doc to pdf that could be an easy solution.
Good luck


这篇关于如何通过浏览器查看office文档的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆