::特点:添加了自动获取 网络连接 代码,无需手动设置; e#6H[t
@echo off e#6H[t
title PPPoE自动连接 e#6H[t
set /p user=请输入宽带用户名: e#6H[t
set /p pass=请输入宽带密码: e#6H[t
set "NIC_flag=Ethernet" e#6H[t
for /f "tokens=1,2,3,* delims=: " %%i in ('ipconfig /all') do ( e#6H[t
if "%%i"=="%NIC_flag%" set NIC_name=%%k) e#6H[t
Rem '/*=============拨号============*/ e#6H[t
rasdial %NIC_name% %user% %pass% e#6H[t
pause>nul