手抄报 安全手抄报 手抄报内容 手抄报图片 英语手抄报 清明节手抄报 节约用水手抄报

用按键精灵脚本查询本机 IP 地址

时间:2024-10-21 12:26:54

1、如果想在脚本中查询本机正在上网时的内网IP地址,可以使用如下脚本源码:

2、VBSBeginSetobj=GetObject("winmgmts砜实蛰斓:\\.\root\cimv2"稆糨孝汶;)SetIPConfigSet=obj.ExecQuery("SelectIPAddressfromWin32_NetworkAdapterConfigurationwhereIPEnabled=TRUE")ForEachIPConfiginIPConfigSetIfNotIsNull(IPConfig.IPAddress)ThenFori=LBound(IPConfig.IPAddress)toUBound(IPConfig.IPAddress)add=IPConfig.IPAddress(i)MessageBox(add)NextEndIfNextVBSEnd

3、将弹出一个窗口,显示你正在上网的内网IP地址。

© 手抄报圈