The demo works, but...

How do I adapt this to only catch messages sent from the form in the external app? I have tried (somewhat wishfully) passing the forms hwnd in instead of using findwindowex to no avail....