HWND GetNextWindow(hWnd,wFlag)
This function searches for a handle that identifies the next (or previous) window in the window-manager's list. The window-manager's list contains entries for all top-level windows, their associated child windows, and the child windows of any child windows. If the hWnd parameter is a handle to a top-level window, the function searches for the next (or previous) handle to a top-level window; if hWnd is a handle to a child window, the function searches for a handle to the next (or previous) child window.
Parameter | Type/Description |
hWnd | HWND Identifies the current window. | ||
wFlag | WORD Specifies whether the function returns a handle to the next window or to the previous window. It can be either of the following values: | ||
Value | Meaning | ||
GW_HWNDNEXT | The function returns a handle to the next window. | ||
GW_HWNDPREV | The function returns a handle to the previous window. |
The return value identifies the next (or the previous) window in the window-manager's list.