Archived

This topic is now archived and is closed to further replies.

kimlee

How can I find hwnd??

Recommended Posts

Dear, I try to make some tools for some commerical games, but how can I get their handle to the window?? Can anyone help me?? Thanks. Regards, kim

Share this post


Link to post
Share on other sites
Lookup FindWindow on MSDN. Most games atleast assign a title to the main window, regardless of whether it''s launched windowed or fullscreen. It shouldn''t be hard to get the handle.

Share this post


Link to post
Share on other sites
After, I look up the FindWindow in MSDN, FindWindow seems to be get a handle only. How can I list all the handle of the window that is running?? Thanks all.

Share this post


Link to post
Share on other sites
GetWindow(hwnd, (flag))

where flag lets you find the child, first, last,next, previous, owner, or enabled popup related to the origin window.

so if you need to create a tree-view listing of them all, this function will let you do that.

The documentation says to use EnumChildWindows for stuff where you want to avoid infinite loops, though.

Share this post


Link to post
Share on other sites