I have searched the forum and tried several of the example pieces of code, but am still struggaling can anyone help me please, beg!!

I am creating another application using VB which needs to to detect various window messgaes such as WM_PAINT, WM_DESTROY etc. The application for which I need to detect these messages is external to my vb app and therefore I belive that I will need create a C/C++ dll to perform a hook and then include this within my vb app. I am only interseting in creating a hook for this one external app and don't need the hook to detect the messages for any other apps that may be running.

For the record:
I have experience writting VB and C programs but very little in writting C++ programs, and yes I have checked MSDN.

Some sample dll code to carry this out would be very much appreciated.

Thanks,

ISquishWorms