How to Disable USB Ports in C#
-
2012년 4월 13일 금요일 오전 4:02
Hello, I have been researching a lot about how to disable a USB port but can't find anything that works.. I have a USB light shining on my keyboard, but, it doesn't turn off when the computer is off... I would like to shut off the power to the USB port completely till I am ready to re-enable it. I would like to disable/enable through a C# program. Thank you in advance! :D
P.S. OS is Win7 x64.
모든 응답
-
2012년 4월 13일 금요일 오전 5:14
Hi Ares2626,
Check below similar thread
http://social.msdn.microsoft.com/Forums/br/winforms/thread/6bc7ceca-4591-42ba-a483-b313d3226ba0
Regards
Purvi
- 답변으로 표시됨 Jason Dot WangMicrosoft Contingent Staff, Moderator 2012년 4월 13일 금요일 오전 8:39
-
2012년 4월 13일 금요일 오전 5:19
And here:
http://social.msdn.microsoft.com/Forums/en/csharpgeneral/thread/f7ef99eb-5d20-4dd1-9d1a-523ad14da0a9
Mitja
- 답변으로 표시됨 Jason Dot WangMicrosoft Contingent Staff, Moderator 2012년 4월 13일 금요일 오전 8:44
-
2012년 4월 13일 금요일 오전 5:34
Refer the link http://sourceforge.net/projects/libusbdotnet/ it might helpful.Manish Maheshwari (MCP)
- 답변으로 제안됨 ManishMaheshwari 2012년 4월 13일 금요일 오전 5:34
- 답변으로 표시됨 Jason Dot WangMicrosoft Contingent Staff, Moderator 2012년 4월 23일 월요일 오전 2:15
-
2012년 4월 13일 금요일 오전 5:38
Why proposing as answer? I really dislike this action.
Mitja
-
2012년 4월 13일 금요일 오전 6:00
BTW, you can try with:
//disable USB storage... Microsoft.Win32.Registry.SetValue(@"HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\USBSTOR", "Start", 4, Microsoft.Win32.RegistryValueKind.DWord); //enable USB storage... Microsoft.Win32.Registry.SetValue(@"HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\USBSTOR", "Start", 3, Microsoft.Win32.RegistryValueKind.DWord);
Mitja
- 답변으로 표시됨 Jason Dot WangMicrosoft Contingent Staff, Moderator 2012년 4월 23일 월요일 오전 2:15

