DOS batch ADSL dial and disconnect

把 ADSL 撥號跟斷線做成 Batch (.bat) 檔。
什麼時候可以用?當用浮動IP ADSL,想要跳IP掃網頁的時候。 😛

@echo off
rem 定義 ADSL 撥號名稱, ID, Password
set adsl=預先設置號的ADSL撥號名稱
set adslid=YOUR_ID
set adslpw=YOUR_PASSWORD

:start
rem 斷線 / disconnect
Rasdial %adsl% /disconnect

rem 撥號連線 / dial
Rasdial %adsl% %adslid% %adslpw%

Leave a Reply

Your email address will not be published. Required fields are marked *