Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
Batch Script Help
Name: techhelp00 Date: March 15, 2007 at 14:55:00 Pacific OS: Windows CPU/Ram: 2.6/1GB Product: Dell
Comment:
I need some help writing a batch script to do the following:
First check to see if Network connection is on DHCP. If it is, exit. If not, change the DNS Server IP address to specified static IPs.
This is what I have for changing the IP...I just don't know how to check for DHCP and exit if it is or continue if it is not DHCP.
netsh interface ip set dns name="Local Area Connection" source=static addr=192.168.1.1 register=PRIMARY netsh interface ip add dns name="Local Area Connection" addr=192.168.1.2 index=2
netsh interface ip set dns name="Local Area Connection 2" source=static addr=192.168.1.1 register=PRIMARY netsh interface ip add dns name="Local Area Connection 2" addr=192.168.1.2 index=2
Summary: I need help with a batch script that will do the following: Check to see if any folders or files exist in C:\Temp and if it does delete all folder in C:\Archive. If no folders or files exist in C:\Tem...
Summary: Hello. I've just registered and wondered if you fine people could help me out on a simple batch script programme. I've never done any before and I have to write one that uses the below ideas: Create ...
Summary: I am looking for some help in writing a batch script. What I want to do is suppose that I have a text file with contents as: 1)a 2)b 3)c 4)d Now in some folder C:\Output I have some files with extensi...