OTTOMH, set up a timer that fires say every 500 ms. In the timer,
check Application.active, if not active close the modal window. Untested. :-)
At 07:48 AM 4/4/2012, John Barrat wrote:
I have an application which needs to close a modal form if focus is
moved to another application.
Effectively, I want to be able to use moving away and to another
application to effect a cancel on the modal form.
The problem is that by the time the deactivate event has occurred
the parent application to which the form is modal is now
inactive. Can anyone suggest a way around this?
JohnB
_______________________________________________
Delphi mailing list
[email protected]
http://lists.elists.org/cgi-bin/mailman/listinfo/delphi
_______________________________________________
Delphi mailing list
[email protected]
http://lists.elists.org/cgi-bin/mailman/listinfo/delphi