打印

[求助] 实用的问题--急急!!!

实用的问题--急急!!!

求解:公司用了一个无线路由器,可以连接30个用户左右,但是每次用户启动电脑的时候,无线就自动的连上了,导致需要无线的用户有时候连不上去(用户大于30),或很久才能连上无线,用户抱怨无线有问题。所以请问各位是否有什么命令(脚本或批处理)可以设置每次电脑启动时就把无线网卡Disabled,等需要使用的时候就Enabled。

TOP

米有用过无线的,都是用网线的

TOP

这个问题要看怎么考虑了.! O5 K: A* b2 H9 J4 q, i
有线网卡的人也需要使用无线吗?
! Q2 i: G0 v8 w! q: c! c& `
3 w* u& P* s" l电脑如何区分是不是该用无线了?

TOP

2003系统可以用这个命令:
1 T- l+ y) q* _9 L) Qnetsh interface set interface name="Wireless Network Connection" admin=DISABLED
! b: M, t7 c1 Z9 p1 O
/ C9 n2 k! o) K2000/XP系统需要使用VBS

TOP

可以参照这段代码改改:
复制内容到剪贴板
代码:
Const ssfCONTROLS = 3
sConnectionName = "本地连接" '可改成需要控制的连接名称,如"无线网络连接"等
sEnableVerb = "启用(&A)"
sDisableVerb = "停用(&B)" 非xp 系统可能 是禁用
set shellApp = createobject("shell.application")
set oControlPanel = shellApp.Namespace(ssfCONTROLS)
set oNetConnections = nothing
for each folderitem in oControlPanel.items
if folderitem.name = "网络连接" then
set oNetConnections = folderitem.getfolder: exit for
end if
next
if oNetConnections is nothing then
msgbox "未找到网络连接文件夹"
wscript.quit
end if
set oLanConnection = nothing
for each folderitem in oNetConnections.items
if lcase(folderitem.name) = lcase(sConnectionName) then
set oLanConnection = folderitem: exit for
end if
next
if oLanConnection is nothing then
msgbox "未找到 '" & sConnectionName & "' item"
wscript.quit
end if
bEnabled = true
set oEnableVerb = nothing
set oDisableVerb = nothing
s = "Verbs: " & vbcrlf
for each verb in oLanConnection.verbs
s = s & vbcrlf & verb.name
if verb.name = sEnableVerb then
set oEnableVerb = verb
bEnabled = false
end if
if verb.name = sDisableVerb then
set oDisableVerb = verb
end if
next
'debugging displays left just in case...
'
'msgbox s ': wscript.quit
'msgbox "Enabled: " & bEnabled ': wscript.quit
'not sure why, but invokeverb always seemed to work
'for enable but not disable.
'
'saving a reference to the appropriate verb object
'and calling the DoIt method always seems to work.
'
if bEnabled then
' oLanConnection.invokeverb sDisableVerb
oDisableVerb.DoIt
else
' oLanConnection.invokeverb sEnableVerb
oEnableVerb.DoIt
end if
'adjust the sleep duration below as needed...
'
'if you let the oLanConnection go out of scope
'and be destroyed too soon, the action of the verb
'may not take...
'
wscript.sleep 400

TOP

我没用过无线的不清楚了

TOP