How to change multiple PC's gateways in one shot, possible a script of some sort

I currently have a script that will change a computers gateway by double clicking on the batch file that I created.  Very simple batch file script, i have pasted it below.

netsh interface ip set address name="Local Area Connection" gateway= gwmetric=0
We have several gateways in our network, for various reasons.  But, I would like to change 10 computers gateways at one shot.  Is there any guru out there that can help we.  Even If you have changed just two or more PC's gateway by simplfying for users.  Your help will be gratiously appreciated. Also, if there is anyway possible for this to happen, where a group policy, preferably a script, or some command.  Please let me know.

Thank you,

Who is Participating?
MCPJoeConnect With a Mentor Commented:
One way I do this is with Automate from a company called Network Automation, you can create your scripts, create variables and run your script to read from a text file of the PCs you want to change.  It will look through and execute your script automatically.  
Naser GabajE&P Senior Software SpecialistCommented:
Greetings shirwaziri,

Check this please:

Good Luck!

You cold use your simple batch script and run it from login script.
You cold trigger it with “user name” or something like that.

And it should be possibly to run from GPO.

Running CMD command like this from script you need to call it like this.

cmd.exe /c netsh interface ip set address name="Local Area Connection" gateway= gwmetric=0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.