zoukankan
html css js c++ java
设置IP的VBS
今天整理资料,看到一段同事上半年写的VBS。上半年有大量服务器要求换IP地址,由于是半夜,做个AT就省事多了。
strComputer
=
"
.
"
Set
objWMIService
=
GetObject
(
"
winmgmts:\\
"
&
strComputer
&
"
\root\cimv2
"
)
Set
colNetAdapters
=
objWMIService.ExecQuery _
(
"
Select * from Win32_NetworkAdapterConfiguration where IPEnabled=TRUE
"
)
strIPAddress
=
Array
(
"
218.5
.
"
)
'
IP Addr.
strSubnetMask
=
Array
(
"
255.255.255.224
"
)
'
子网掩码
strGateway
=
Array
(
"
218.5
"
)
'
网关
strGatewayMetric
=
Array
(
1
)
For
Each
objNetAdapter in colNetAdapters
errEnable
=
objNetAdapter.EnableStatic(strIPAddress, strSubnetMask)
errGateways
=
objNetAdapter.SetGateways(strGateway, strGatewaymetric)
Next
查看全文
相关阅读:
The EF 6.x DbContextGenerator templates are not available for VS2010
selenium定位tr及td,并获取其文本及属性
selenium基本操作
Git入门
独热编码OneHotEncoder简介
openCV中直方图均衡化算法的理解
pyinstaller生成exe文件失败
图像形态学运算
对双边滤波的理解
PyQt中对RadioButton分组
原文地址:https://www.cnblogs.com/LCX/p/629249.html
最新文章
[leetcode]_Pascal's Triangle
[leetcode]_Merge Sorted Array
[leetcode]_Remove Duplicates from Sorted Array II
[leetcode]_Climbing Stairs
[leetcode]_Unique Paths
[leetcode]_Count and Say
[leetcode]_Valid Sudoku
ASP.NET MVC 分页之 局部视图
ASP.NET MVC 分页之HtmlHelper
ASP.NET MVC 随手记
热门文章
C# 语法特性
Windows的历史zt
完美解决IE(IE6/IE7/IE8)不兼容HTML5标签的方法zt
@RenderSection
<meta http-equiv="Pragma" content="no-cache">
让vs2010的html编辑器验证html5语法
charset
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">的含义
实体类上的一对一关系需要手动指定
在实体对象中访问导航属性里的属性值出现异常“There is already an open DataReader associated with this Command which must be closed first”
Copyright © 2011-2022 走看看