下面的例子显示了如何使用命令设置IP,网关和DNS
netsh interface ip set address "本地连接" static 192.168.0.180 255.255.255.0 192.168.0.1 1
netsh interface ip set dns "本地连接" static 210.22.70.3 primary
netsh interface ip add dns "本地连接" 210.22.84.3 index=2
下面的例子显示了如何使用命令设置IP,网关和DNS
netsh interface ip set address "本地连接" static 192.168.0.180 255.255.255.0 192.168.0.1 1
netsh interface ip set dns "本地连接" static 210.22.70.3 primary
netsh interface ip add dns "本地连接" 210.22.84.3 index=2