Is it possible to create a win32 messaging window that cannot be found by enumeration?

I am trying to list all win32 windows using the following code:

EnumChildWindows(GetDesktopWindow(),
                 WindowManager::enumChildWindows,
                 reinterpret_cast<LPARAM>(this));

BOOL CALLBACK WindowManager::enumChildWindows(HWND hwnd, LPARAM lParam) {
    WindowManager* manager = reinterpret_cast<WindowManager*>(lParam);

    //
    // Do stuff with child window handle (hwnd)
    //

    // Return TRUE to continue enumeration, FALSE to stop.
    return TRUE;
}

Basically, I get the topmost window by calling a function GetDesktopWindow( VOID )from WinAPI and listing the child windows, calling the function EnumChildWindows( __in_opt HWND hWndParent, __in WNDENUMPROC lpEnumFunc, __in LPARAM lParam)again from WinAPI.

Just my question is: can I skip any win32 window with this approach? Can someone hide win32 window so this approach cannot list it?

Thanks in advance.

+4
source share
1 answer

( EnumChildWindows (GetDesktopWindow)) - : .   EnumChildWindows (GetAncestor (FindWindowEx (HWND_MESSAGE, 0,0,0), GA_PARENT)): . FindWindow , EnumChildWindows ?.

+2

All Articles