◄Function Group► ◄Overview► ◄Up► ◄Next► ◄Previous► ──────────────────────────────────────────────────────────────────────────── #define INCL_WINMESSAGEMGR BOOL WinSetOwner(hwnd, hwndNewOwner) HWND hwnd; /* handle of the window whose owner is changed */ HWND hwndNewOwner; /* handle of the new owner window */ The WinSetOwner function changes the owner of a specified window. The owner window and the owned window must have been created by the same thread. The WinQueryWindow function can be used to obtain the handle of the owner window. Parameter Description ──────────────────────────────────────────────────────────────────────────── hwnd Identifies the window whose owner is changed. hwndNewOwner Identifies the new owner window. If this parameter is NULL, the window's owner is set to NULL. Return Value The return value is TRUE if the function is successful or FALSE if an error occurs. See Also WinQueryWindow, WinSetParent ♦