http://www.perlmonks.org?node_id=240500


in reply to Change Windows DNS Settings

Ok, this won't work for Win9x, but a much more robust solution for Win2k/XP is the following:
netsh interface ip add dns "Local Area Connection" 10.10.10.10 index=1 netsh interface ip delete dns "Local Area Connection" 10.10.10.10
Look at the netsh for more options and details. There is a ton of stuff you can do with netsh including changing IP's, netmasks, routes, adding deleting (non-LAN) interfaces, etc.

"Nothing is sure but death and taxes" I say combine the two and its death to all taxes!