#电信网络
@echo off
netsh interface ipv4 set address "本地连接" static 192.168.20.80 255.255.255.0 192.168.20.253netsh interface ipv4 set dns "本地连接" static 114.114.114.114 primarynetsh interface ipv4 add dns "本地连接" 218.30.19.40 index=2ipconfig#pause
#网通网络
@echo offnetsh interface ipv4 set address "本地连接" static 192.168.20.80 255.255.255.0 192.168.20.254ipconfig#pause请保存为.bat格式的文件
如果系统不是以管理员登录、点击右键用管理员身份运行.bat文件