打开ms word / excel应用程序而不使用activeXObject进行跨浏览器 [英] Open ms word/excel applications without using activeXObject for cross browser

查看:338
本文介绍了打开ms word / excel应用程序而不使用activeXObject进行跨浏览器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

function OpenFile(){
alert ('Work');
//would like to modify ActiveXObject with any other object for cross-browser.
var x = new ActiveXObject("WScript.Shell");
x.run('winword.exe');
}
//Above code works only in IE. But don't want to use activeXObject.
//Is there any possibility to open a word file in Internet Explorer
//without using activexobject. Request for a solution.

推荐答案

我已经尝试了这个,但实际上这并不是那么容易,有像Excel / Word这样的应用程序提供的整套功能。



最终在客户端计算机上显示excel或word是一团糟,我试过并陷入执行困境宏。



据我所知,在所有浏览器中都不允许使用word / excel,甚至AcitveX对象也不会让你使用大部分功能。



尝试找一些其他解决方案,如果可能,我必须在网页上显示PremiumCalculator excel而不是让人们下载相同的内容,我继续在asp中创建一个PremiumCalculator .net,而不是在Web浏览器中显示现有工作表。
I have tried this sometime back but then this is not actually that easy, there is whole set of functionality that comes up with an application like Excel/Word.

Ultimately displaying excel or word on client machine is a mess, I tried and got stuck in executing macros.

There is nothing to my knowledge that would allow word/excel to be given in all the browser, even AcitveX objects wont let you use most of the functionality.

Try find some other solution if possible, I has to display a PremiumCalculator excel in webpage instead of letting people download the same, I went ahead and created a PremiumCalculator in asp.net, instead of displaying the existing sheet in web browser.


这篇关于打开ms word / excel应用程序而不使用activeXObject进行跨浏览器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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