日期:2014-05-17  浏览次数:21158 次

急!ASP如何获取服务器端MAC地址?
希望各位高手能给出详细的代码!不是获得客户端的MAC地址喔!谢谢!

------解决方案--------------------
需要IIS中网站的匿名访问用户改为Administrator帐号
VBScript code

<%
Set colIPConfig = GetObject("winmgmts:{impersonationLevel=impersonate}!\\.\root\cimv2" ).ExecQuery ("SELECT MACAddress FROM Win32_NetworkAdapterConfiguration WHERE IPEnabled=true" )
For Each oIPConfig In colIPConfig
    Response.Write oIPConfig.MACAddress & "<br>"
Next
%>

------解决方案--------------------
高,实在是高!
------解决方案--------------------
1楼正解。呵呵。