Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to use EnumWindows ?

Status
Not open for further replies.

Leibnitz

Programmer
Apr 6, 2001
393
CA
Can somedy provide me some elementary sample code on how to use "EnumWindows"( none MFC if possible );

Thanks in advance !
 
LPARAM lParam = 0; //param to use
EnumWindows( EnumWindowsProc, lParam); //usage

BOOL CALLBACK EnumWindowsProc( HWND hWnd, LPARAM lParam )
{
//This function will be called on each Window!

// return FALSE to stop enumeration
EnumChildWindows(hWnd, EnumWindowsProc, lParam); //You can enumerate child windows too
return TRUE; //continue enumeration
}
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top