How do I detect insertion of USB devices category wise in C# winform?
问题 USB thumb drives USB harddisks USB DVD writer USB Bluetooth devices USB headsets usb mouse USB keyboard USB webcams / cameras Just want to detect any sort of usb device using event handler... Would appreciate any help... WqlEventQuery q_creation = new WqlEventQuery(); private void Form2_Load(object sender, EventArgs e) { q_creation.EventClassName = "__InstanceCreationEvent"; q_creation.WithinInterval = new TimeSpan(0, 0, 2); //How often do you want to check it? 2Sec. q_creation.Condition = @