为了正常的体验网站,请在浏览器设置里面开启Javascript功能!

vbs脚本 实现无线网络连接与本地连接的网卡禁用启用完美切换(优化版)(VBS scripts enable wireless network connections and local connections to the network card. Disable enabling perfect sw..

2017-10-13 7页 doc 23KB 292阅读

用户头像

is_321575

暂无简介

举报
vbs脚本 实现无线网络连接与本地连接的网卡禁用启用完美切换(优化版)(VBS scripts enable wireless network connections and local connections to the network card. Disable enabling perfect sw..vbs脚本 实现无线网络连接与本地连接的网卡禁用启用完美切换(优化版)(VBS scripts enable wireless network connections and local connections to the network card. Disable enabling perfect sw.. vbs脚本 实现无线网络连接与本地连接的网卡禁用启用完美切换 (优化版)(VBS scripts enable wireless network connections and local connections t...
vbs脚本 实现无线网络连接与本地连接的网卡禁用启用完美切换(优化版)(VBS scripts enable wireless network connections and local connections to the network card. Disable enabling perfect sw..
vbs脚本 实现无线网络连接与本地连接的网卡禁用启用完美切换(优化版)(VBS scripts enable wireless network connections and local connections to the network card. Disable enabling perfect sw.. vbs脚本 实现无线网络连接与本地连接的网卡禁用启用完美切换 (优化版)(VBS scripts enable wireless network connections and local connections to the network card. Disable enabling perfect switching (optimized version)) The VBS script implements the "wireless network connection" and the "local connection" network card to disable enabling perfect switching (optimized version) It was possible to use only one VBS, but with only one VBS, it was a bit of a hassle to select a local connection or a wireless connection every time the user chooses. Therefore, local connections and wireless connections are enabled, placed in different VBS scripts, and run one of the scripts as needed. The following result is "enable Wireless.vbs" code of communism '----------------- started developing wireless network related services Set vbs=CreateObject ("Wscript.Shell") '***************Wireless Zero Configuration Vbs.Run "SC, config, WZCSVC, start=, demand"" Vbs.Run "SC start WZCSVC"" '***************Atheros configuration services Vbs.Run "SC, config, ACS, start=, demand"" Vbs.Run "SC start ACS"" Wscript.sleep 1000 SEnableConnectionName = wireless network connection" SDisableConnectionName = local connection" Const ssfCONTROLS = 3 SEnableVerb = "enable" (&A)" SDisableVerb = disable (&B)" Set shellApp = CreateObject ("shell.application") Set oControlPanel = shellApp.Namespace (ssfCONTROLS) Set oNetConnections = nothing For, each, folderitem, in, oControlPanel.items If folderitem.name = "network connection" Then Set oNetConnections = folderitem.getfolder:, exit, for End if Next If, oNetConnections, is, nothing, then Msgbox "no network and dial up Connections folder found" Wscript.quit End if '----------------- stopped developing connection Set oLanConnection = nothing For, each, folderitem, in, oNetConnections.items If lcase (folderitem.name) = lcase (sDisableConnectionName) then Set oLanConnection = folderitem:, exit, for End if Next If, oLanConnection, is, nothing, then Msgbox "not found" - & sDisableConnectionName & item" Else Set oEnableVerb = nothing Set oDisableVerb = nothing For, each, verb, in, oLanConnection.verbs If verb.name = sDisableVerb then Set oDisableVerb = verb Exit For End if Next If not (oDisableVerb, is, nothing) then ODisableVerb.DoIt End if End If '----------------- developing to enable the connection Set oLanConnection = nothing For, each, folderitem, in, oNetConnections.items If lcase (folderitem.name) = lcase (sEnableConnectionName) then Set oLanConnection = folderitem:, exit, for End if Next If, oLanConnection, is, nothing, then Msgbox "not found" - & sEnableConnectionName & item" Else Set oEnableVerb = nothing Set oDisableVerb = nothing For, each, verb, in, oLanConnection.verbs If verb.name = sEnableVerb then Set oEnableVerb = verb Exit For End if Next If not (oEnableVerb, is, nothing) then OEnableVerb.DoIt 最后如果 最后如果 wscript.sleep 1000 ********以下是”启用本地连接.vbs”的代码******** senableconnectionname =“本地连接” sdisableconnectionname =“无线网络连接” const ssfcontrols = 3 senableverb =“启用(&)” sdisableverb =“停用(& B)” 集shellapp = CreateObject(“壳”中的应用) 集ocontrolpanel = shellapp命名空间(ssfcontrols)。 集onetconnections =没有 每个folderitem在ocontrolpanel.items 如果folderitem.name =“网络连接”然后 集onetconnections = folderitem.getfolder:退出 最后如果 下一个 如果onetconnections是没有然后 本未找到网络和拨号连接文件夹” wscript.quit 最后如果 “-----------------停用连接----------------- 集olanconnection =没有 每个folderitem在onetconnections.items 如果1例(folderitem。名字)= 1例(sdisableconnectionname)然后 集olanconnection = folderitem:退出 最后如果 下一个 如果olanconnection是没有然后 本未找到”与sdisableconnectionname &“'项目” 其他的 集oenableverb =没有 集odisableverb =没有 每个动词在olanconnection.verbs 如果verb.name = sdisableverb然后 集odisableverb =动词 退出 最后如果 下一个 如果不是(odisableverb什么)然后 odisableverb.doit 最后如果 最后如果 “-----------------启用连接----------------- 集olanconnection =没有 每个folderitem在onetconnections.items 如果1例(folderitem。名字)= 1例(senableconnectionname)然后 集olanconnection = folderitem:退出 最后如果 下一个 如果olanconnection是没有然后 本未找到”与senableconnectionname &“'项目” 其他的 集oenableverb =没有 集odisableverb =没有 每个动词在olanconnection.verbs 如果verb.name = senableverb然后 集oenableverb =动词 退出 最后如果 下一个 如果不是(oenableverb什么)然后 oenableverb.doit 最后如果 最后如果 wscript.sleep 800 “-----------------停止无线网络相关服务----------------- 设置VBS = CreateObject(“wscript。壳”) “***************无线零配置 VBS。运行“SC停止WZCSVC” VBS。运行“sc config WZCSVC开始=禁用” “*************** Atheros配置服务 VBS。运行“SC阻止ACS” VBS。运行“SC配置ACS开始=禁用”
/
本文档为【vbs脚本 实现无线网络连接与本地连接的网卡禁用启用完美切换(优化版)(VBS scripts enable wireless network connections and local connections to the network card. Disable enabling perfect sw..】,请使用软件OFFICE或WPS软件打开。作品中的文字与图均可以修改和编辑, 图片更改请在作品中右键图片并更换,文字修改请直接点击文字进行修改,也可以新增和删除文档中的内容。
[版权声明] 本站所有资料为用户分享产生,若发现您的权利被侵害,请联系客服邮件isharekefu@iask.cn,我们尽快处理。 本作品所展示的图片、画像、字体、音乐的版权可能需版权方额外授权,请谨慎使用。 网站提供的党政主题相关内容(国旗、国徽、党徽..)目的在于配合国家政策宣传,仅限个人学习分享使用,禁止用于任何广告和商用目的。

历史搜索

    清空历史搜索