如何从网页运行可执行文件? [英] How to run a executable file from a web page?
问题描述
我的意思是,当用户点击网页上的按钮时,
已经安装在他的计算机上的程序将被执行
。我还需要将一些命令行参数传递给程序。
What I mean is, when user click a button on a webpage, a program which has already installed on his computer would be executed. I also need to pass some command line parameters to the program.
我们有2个程序,一个是Web应用程序,另一个是桌面程序。
我们希望找到一种简单的方法来集成2.
这就是我们需要从网页执行桌面程序的原因。
We have 2 program, one is a web app, the other is a desktop program. We want to find a simple way to integrate the 2. That's why we need to execute the desktop program from a web page.
推荐答案
您可以向您的应用程序注册协议,以便导航到以该方案开头的URL将启动您的应用程序并运行命令。
You can register a protocol to your application so that navigating to a URL beginning with that scheme will launch your application and run a command.
- [Windows](http://msdn.microsoft.com/en-us/library/aa767914(VS.85).aspx)
- Mac OS X
- Gnome
这篇关于如何从网页运行可执行文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!