Solved

Determine top but unfocused window handle

Posted on 2002-05-08
6
134 Views
Last Modified: 2010-04-04
How can I determine the top window handle but it doesn't have any focus? Like when you have a window open and it has focus and you click on the clock in the tray. It looses focus but it is still the top window on the desktop. Thanx in advance.
0
Comment
Question by:skynergy
6 Comments
 
LVL 27

Expert Comment

by:kretzschmar
ID: 6996385
>it has focus and you click on the clock in the tray. It >looses focus but it is still the top

are your sure?
isn't it so that the taskbar(window) is then on top
(and there is just no overlap)

just for rethinking

meikl ;-)
0
 
LVL 3

Expert Comment

by:raidos
ID: 6996452
meikl, the taskbar(window) is normally "Always on Top" unless somebody changed the setting.. =)

Also note that the Desktop(window) is normally always below "all" other windows even if it does have focus.

Regards
//raidos
0
 
LVL 3

Accepted Solution

by:
raidos earned 25 total points
ID: 6996468
I would Advise you too check the Win32 API for GetTopWindow and GetNextWindow, in those lie the answers you seek i think.

//raidos
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 4

Assisted Solution

by:nestorua
nestorua earned 25 total points
ID: 6997031
HI,
If you want to know the Handle of the Top Window
(in Z-order) then use GetTopWindow() function.
But it is not the same as Focused Window.
So you must tell more fully what you mean when say "the top".
Sincerely,
Nestorua.
0
 
LVL 1

Expert Comment

by:pnh73
ID: 9005252
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:

Split between raido and netorua

Please leave any comments here within the next seven days.
 
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
 
Paul (pnh73)
EE Cleanup Volunteer
0
 
LVL 1

Expert Comment

by:pnh73
ID: 9005303
[ Sorry I missed out all my s's in that last post... It should be "Split between raidos and nestorua" ]

Paul (pnh73)
EE Cleanup Volunteer
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
This tutorial gives a high-level tour of the interface of Marketo (a marketing automation tool to help businesses track and engage prospective customers and drive them to purchase). You will see the main areas including Marketing Activities, Design …
Both in life and business – not all partnerships are created equal. As the demand for cloud services increases, so do the number of self-proclaimed cloud partners. Asking the right questions up front in the partnership, will enable both parties …

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now