从ActiveX控件获取计算机名称 [英] Get Computer Name from ActiveX control

查看:81
本文介绍了从ActiveX控件获取计算机名称的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

hii。

我在Asp.net中使用activex Control需要客户端的计算机名称.C#

给我一些解决的例子。

解决方案

我在google上发现了这个:



使用C#编写ActiveXcrement控件 [ ^ ]



但是除了技术障碍之外,大多数人甚至都没有使用IE,因此,除非你需要用户,否则activeX控件是不可行的使用IE浏览器。任何半脑的人都不允许ActiveX控件从浏览器运行,所以除非你的用户在企业内部网上要求他们使用IE,否则你的实现将是垃圾。


< blockquote> var WinNetwork = new ActiveXObject(WScript.Network);

alert(系统名称为:+ WinNetwork.ComputerName);


hii.
I need client's computer name using activex Control in Asp.net.. C#
Send me some solved Example.

解决方案

I found this on google:

Writing an ActiveXcrement control with C#[^]

But over and above the technical hurdles, most people aren't even using IE, and therefore, and activeX control isn't viable unless you REQUIRE users to be using IE. Anyone with half a brain wouldn't allow ActiveX controls to run from the browser, so unless your users are on a corporate intranet that REQUIRES them to use IE, you're implementation will be garbage.


var WinNetwork = new ActiveXObject("WScript.Network");
alert("Sys name is : " + WinNetwork.ComputerName);


这篇关于从ActiveX控件获取计算机名称的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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