enable / disable network interface through scripts.

Hello
How can I enable / disable a network card on windows 2003 through a .bat script?
eggster34Asked:
Who is Participating?
 
Rob WilliamsCommented:
To disable:
netsh interface set interface “Local Area Connection” disabled
To enable:
netsh interface set interface “Local Area Connection” enabled

Must be run by an admin, and spelling of your network adapter name, such as; “Local Area Connection”, must be exact.
0
 
sirbountyCommented:
If that's not it, you may can get this working with devcon...http://support.microsoft.com/kb/311272
0
 
Rob WilliamsCommented:
netsh works on 2003 but you will need sirbounty's option if using XP or other.
0
 
Rob WilliamsCommented:
Thanks eggster34.
Cheers !
--Rob
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.