My apologies for such a vague an open ended question. I do realise that the reason could be almost anything, but that's the problem and I need some general advice on how to debug the issue.
I'm making really goo progress with an application that uses ASyncCalls and MouseInput.Click() to programatically do mouse clicks for the user.
Pretty much everything is working as required now with all clicking variations needed working.
However, when the application does a left click over the 'Close' button of the main form - to exit the application - the application hangs until the mouse is manually clocked again. The application starts running again as soon as the mouse button is manually clicked (I can see this because the UI also has a mouse coordinated tracker in the title bar). If this manual click is on the Close button the form DOES close.
I can't work out what could be causing this unless it's something to do with the ASyncCall to MouseInput.Click() not having finished (even thought the click appears to have happened before the hang).
And I don't know where to start looking.
I've attached a demo of the problem in a simplified project - this project pulls together a few of the things I've been working on in the actual application, including the transparent underlay that can be enabled using the checkbox.
In the demo application left-click, right-click etc work as expected anywhere on the screen. Except that left-click on the close button of the application itself does not close the app, but freezes it.
Thanks,
FM