[DllImport("user32.dll", SetLastError = true)]
static extern IntPtr RegisterDeviceNotification(IntPtr hRecipient,
IntPtr NotificationFilter, uint Flags);
<DllImport("user32.dll", CharSet:=CharSet.Auto, SetLastError:=true)> _
Function RegisterDeviceNotification(ByVal hRecipient As IntPtr, _
ByVal NotificationFilter As IntPtr, _
ByVal Flags As Int32) _
As IntPtr
End Function
None.
The DEVICE_NOTIFY_WINDOW_HANDLE constant is defined in dbt.h. The formHandle and DevBroadcastDeviceInterfaceBuffer parameters are IntPtr variables. The function returns an IntPtr in deviceNotificationHandle.
Please add some!
Public Const DEVICE_NOTIFY_WINDOW_HANDLE As Integer = 0
deviceNotificationHandle=RegisterDeviceNotification(formHandle, DevBroadcastInterfaceBuffer, DEVICE_NOTIFY_WINDOW_HANDLE)
Do you know one? Please contribute it!