Google Answers Logo
View Question
 
Q: Last active window from system tray application ( No Answer,   0 Comments )
Question  
Subject: Last active window from system tray application
Category: Computers > Programming
Asked by: wordweb-ga
List Price: $20.00
Posted: 11 Feb 2004 17:38 PST
Expires: 12 Mar 2004 17:38 PST
Question ID: 305964
In Windows programming, I have an application that sits on the system
tray (see wordweb.info). I cannot find any 100% reliable way to get the
last active program when a user clicks on the icon. For example, if
someone was using IE, moved the mouse and clicked on my icon, I'd like
to get the handle to the IE window they are using. 

I do not want to set up a system wide hook - there must be any easier
way! GetForegroundWindow on a mouse over event does return the right
handle, but you aren't guaranteed to get a mouse over event before the
click. I can kludge something that works most of the time, but I'd
like a simple reliable way to do it.
Answer  
There is no answer at this time.

Comments  
There are no comments at this time.

Important Disclaimer: Answers and comments provided on Google Answers are general information, and are not intended to substitute for informed professional medical, psychiatric, psychological, tax, legal, investment, accounting, or other professional advice. Google does not endorse, and expressly disclaims liability for any product, manufacturer, distributor, service or service provider mentioned or any opinion expressed in answers or comments. Please read carefully the Google Answers Terms of Service.

If you feel that you have found inappropriate content, please let us know by emailing us at answers-support@google.com with the question ID listed above. Thank you.
Search Google Answers for
Google Answers  


Google Home - Answers FAQ - Terms of Service - Privacy Policy