Recogize if Hardware has changed, WndProc

Recogize if Hardware has changed, WndProc

Hi,
i have to recognize if hardware changes (Usb-Stick is plugged in).
i found an idea in the internet, which works on a normal C# Programm

const int WM_DEVICECHANGE = 0x0219; //see msdn site
protected override void WndProc(ref Message m)
{
if (m.Msg == WM_DEVICECHANGE)
{
//do something
}
base.WndProc(ref m);
}
but in VSTA the base.WndProc(ref m) statement is not possible.
There is the message: 'zenOn.ProjectEntryPoint' does not contain a definition for 'WndProc'
Is there any solution for this problem ?
Thanks

This is a migrated post! Originally posted on 03.06.2013 by user armins. Please be aware that information can be outdated.