Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I would like to disable the local network card (only one in the computer) by using this command:

wmic path win32_networkadapter where index=7 call disable

return value is 5 (access denied). I don't know what the problem is.

The current user has admin rights (it is not actually the admin but has admin rights). Operating system is win7 professional.

When I activate the admin account and perform this command under this admin account everything works. But I don't wont to keep the real admin account enabled. runas isn't an option also.

It seems that I'm missing a specific right to run this command. Does anyone know what to do? Thank you!

share|improve this question

migrated from stackoverflow.com Jan 16 '13 at 9:01

This question came from our site for professional and enthusiast programmers.

1 Answer 1

Have you tried PowerShell?

Disable-NetAdapter -Name 'YourNic'

Here is an article I wrote on Enabling / Disabling NICs with PowerShell

Note: You need PowerShell v 3.0.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.