问题描述
世界您好! :)
我有一种情况,我想不出什么是解决该问题的最干净的"方法,谢谢您事先提出的任何想法.
问题:
我需要构建一个Web应用程序,其中客户端窗体需要从C#DLL驱动的硬件中获取输入.其中一些DLL具有需要激活的应用程序/会话范围.
解决方法:
-最简单的方法是使用隐藏框架,该框架使用JavaScript ActiveXObject()控制硬件DLL的活动和读数.
-另一个选择是以某种方式使我的Hw控制器成为IE浏览器的附加组件",并从JavaScript调用它.我认为这可以通过浏览器帮助器对象以及通过以下方式在JavaScript中进行调用来实现:navigator.MyController.
-进行后台服务以启动/停止硬件通信,并将控制器从JavaScript中分离出来.
有帮助/意见吗?
请避免不是推荐方法的烈火大战. :)
Hello world! :)
I have a situation which I can''t figure what it will be the "cleanest" way to solve it Thanks for any ideas in advance.
Problem:
I need to build a web application in which the client forms need to get input from hardware that is driven by C# DLLs. Some of these DLLs have an application / session scope for which they need to be active.
Workarounds:
- The easiest way will be to use a hidden-frame which uses JavaScript ActiveXObject() to control the Hw DLL activity and readings.
- Another option will be to somehow make my Hw controller as an IE browser "addon" and call it from JavaScript. I think this is doable through Browser Helper Objects and some how make calls in JavaScript as: navigator.MyController.
- Make a background service which start / stop the Hw communication and separate the controller to be what is call from JavaScript.
Any help / opinions?
Please avoid a flame war of not being a recommend approach. :)
推荐答案
这篇关于Web应用程序如何与客户端硬件对话?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!