Netsh is good for batching and it is handy since it covers many different
network settings. I don't think it can change the computer name, though.
To avoid some problems with netsh on a milogon build (not registered named
network connections) I had to create my our tool pack to change IP, computer
name and etc.
Thanks for the discussion,
KM
SLe> KM,
SLe> I remember reading in the help that Netsh can change the computer
SLe> name, but
SLe> I could be wrong. Netsh is too complicated for what most people
SLe> want to do;
SLe> I prefer using utilities like the one Hiedi created for static
SLe> TCP/IP on xpefiles.com.
SLe> Regards,
SLe> Sean Liming
SLe>>> KM,
SLe>>> The Netsh.exe solution was posted in the newsgroups some time
SLe>>> ago.
SLe>>> Here is a solution listed:
SLe>>> Set a batch file or script to run during RunOnce, use the command
SLe>>> entries below to have netsh.exe configure the IP for you. You
SLe>>> will also need to add the "Network Command Shell" & "NetSh
SLe>>> Command Shell
SLe>>> Context" & "IP Router
SLe>>> Monitor Library" components.
SLe>>> The batch file/script contents:
SLe>>> netsh interface ip set address name="Local Area Connection"
SLe>>> source=static addr=192.168.1.10 255.255.255.0 192.168.1.1 1
SLe>>> netsh interface ip set dns name="Local Area Connection" static
SLe>>> 192.168.1.2 primary
SLe>>> netsh interface ip add dns name="Local Area Connection"
SLe>>> 192.168.1.3 index=2
SLe>>> netsh interface ip add dns name="Local Area Connection"
SLe>>> 192.168.1.4 index=3
SLe>>> Regards,
SLe>>> Sean Liming
SLe>>> XP Embedded Manager
SLe>>> A7 Enginering (
www.a7eng.com)
SLe>>> Author: Windows XP Embedded Advanced and Windows NT Embedded
SLe>>> Step-by-Step
SLe>>> Step-by-Step
With best regards, KM. E-mail: (e-mail address removed)