|
-
Sep 7th, 2000, 04:39 AM
#1
Thread Starter
Conquistador
how do i find out the class of an application so that i can use the function findwindow, to get its handle?
-
Sep 7th, 2000, 04:47 AM
#2
The class name is normally registred when the window is created.
The only way that I know of to get the class name is to call GetClassName. But that call requires the hWnd of the window. So I suppose that is of no help to you.
-
Sep 7th, 2000, 04:59 AM
#3
Thread Starter
Conquistador
how come megatron knew that ie was "IEFRAME" then?
-
Sep 7th, 2000, 05:41 AM
#4
OK I thought you wanted to know how your program could find out.
You can use SPY++ to get the Class name.
-
Sep 7th, 2000, 06:03 AM
#5
transcendental analytic
There's many way to find out, but the thing is that you find the window handles, not the classes.
Enumwindows, enumerates windows
Windowfrompoint, returns the top window from a position on the screen.
getparent, returns the parent window to a window.
you could do a lot with that already. well, never used spy++ since i made my own
Use  
writing software in C++ is like driving rivets into steel beam with a toothpick.
writing haskell makes your life easier:
reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.
-
Sep 7th, 2000, 06:14 AM
#6
I don't use Spy++ either, I made my own spy tool which can get almost any information about windows (which it stores in a treeview), the only problem I have with the program is the fact that I can't subclass other threads without a DLL.
About your question: You can enumerate the windows using EnumWindows and in the EnumProc check the classname of the window you want.
-
Sep 7th, 2000, 08:29 PM
#7
Thread Starter
Conquistador
well then how do i find out the class through spy++?
also, i do want the class names, so that i can find a window of ie, or word, and make it faster than if i had to enumerate all windows!
-
Sep 8th, 2000, 05:06 AM
#8
Start Spy++ and choose the Find Window tool on the Spy menu.
Drag the Finder Tool to the window you want to find the class for and drop it.
Word 2000 => OpusApp
Best regards
-
Sep 10th, 2000, 04:43 AM
#9
Thread Starter
Conquistador
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|