Changing IP under console in Windows2k/XP
I have to change ip address of my machine frequently, as I'm on serveral different networks. It's boring to open "Network Properties" following serveral mouse-clicks.So I wrote a script that will do the stuff easily. Save below lines as a .bat file, and just one-click:)
@echo off
set dest_ip=192.168.0.240
set dest_mask=255.255.255.0
set dest_gw=192.168.0.2
echo Changing IP to %dest_ip%
rem
netsh interface ip set address local static addr=%dest_ip% mask=%dest_mask% gateway=%dest_gw% gwmetric=1
echo ..............................................................
echo *************Current IP configure***************
ipconfig
echo ..............................................................
pause
close

0 Comments:
Post a Comment
<< Home