I need program made in vb6 to detect when mouse and keyboard are connected or not.
Printable View
I need program made in vb6 to detect when mouse and keyboard are connected or not.
I will really appreciated if someone can help me. thank you very much
Detection is different then telling you WHEN IT DISCONNECTS, which is probably more of what you would like. Provide a LOT more information, if you expect anyone to know what you want to do.
Yeah thank you this what i need to do.. i need function to detect when my keyboard is connected or not. for example when my keyboard is disconnect it will show a msg that the keyboard has been unplugged and msg when its disconnect again..thank you very much
I am only using vb6 so i need function that is compatible in vb6 thank you very much i will really appreciated it if you can help me.. Godbless
I making a program that will lock the screen when the keyboard get disconnected and unlock the screen when the keyboard connect again
This is not the correct way going about this. why lock the screen if there is no input device?
Anyways, if it is a usb mouse and a usb keyboard, you might be able to use the RegisterDeviceNotification API to detect insertion or removal. I have done it with USB drives - and it should work similar.
Thank you Sir. i just lock the system by a screen saver using vb6 i am new in vb6 im still learning thank you for sharing
or msgbox when keyboard/mouse is unplugged of plugged again pls help..... thank you
I thought you would have googled already, based on my previous advice.... :rolleyes:
Anyways, have a decent read through this article I wrote some time ago :
VB 6 and USB Flash Disks
http://www.codeguru.com/vb/gen/vb_sy...cle.php/c14935