Important Notice
The pages on this site contain documentation for very old MS-DOS software,
purely for historical purposes.
If you're looking for up-to-date documentation, particularly for programming,
you should not rely on the information found here, as it will be woefully
out of date.
WinBeginEnumWindows (1.2)
◄Function Group► ◄Overview► ◄Up► ◄Next► ◄Previous►
────────────────────────────────────────────────────────────────────────────
#define INCL_WINWINDOWMGR
HENUM WinBeginEnumWindows(hwnd)
HWND hwnd; /* handle of the parent window */
The WinBeginEnumWindows function begins the enumeration process for all
immediate child windows of a specified window. This function takes a
snapshot of the window hierarchy at the time the function is called and
enumerates the windows in the order they were at the time the snapshot is
taken. The topmost child window is enumerated first, guaranteeing that all
child windows are enumerated.
Parameter Description
────────────────────────────────────────────────────────────────────────────
hwnd Identifies the parent window whose child windows are enumerated.
If this parameter is HWND_DESKTOP, all main windows are
enumerated.
Return Value
The return value is the handle to an enumeration list and is used in
subsequent calls to WinGetNextWindow to retrieve the window handles in
succession. When the application has finished the enumeration, this handle
must be destroyed by the WinEndEnumWindows function.
Comments
The enumerated windows are not locked and can be destroyed between the time
this function is called and the time that the WinGetNextWindow function is
used to obtain the window handle. However, enumerated window handles
referenced by the enumeration handle will be removed from the enumeration
list if they are destroyed. Thus they will not be returned by
WinGetNextWindow.
See Also
WinEndEnumWindows, WinGetNextWindow
♦