From 0f803639a40e65722c08e3332bcbc9e406546bef Mon Sep 17 00:00:00 2001 From: Nikita Leontiev Date: Thu, 6 Nov 2025 13:01:56 +0300 Subject: [PATCH] Return value description update --- sdk-api-src/content/winuser/nf-winuser-setfocus.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sdk-api-src/content/winuser/nf-winuser-setfocus.md b/sdk-api-src/content/winuser/nf-winuser-setfocus.md index f54000814dc..cb9b60b2a7e 100644 --- a/sdk-api-src/content/winuser/nf-winuser-setfocus.md +++ b/sdk-api-src/content/winuser/nf-winuser-setfocus.md @@ -81,6 +81,8 @@ Type: **HWND** If the function succeeds, the return value is the handle to the window that previously had the keyboard focus. If the *hWnd* parameter is invalid or the window is not attached to the calling thread's message queue, the return value is NULL. To get extended error information, call [GetLastError function](../errhandlingapi/nf-errhandlingapi-getlasterror.md). +If the window that previously had the keyboard focus was destroyed after losing focus, the return value is NULL and [GetLastError function](../errhandlingapi/nf-errhandlingapi-getlasterror.md) return value is ERROR_SUCCESS (0). + Extended error ERROR_INVALID_PARAMETER (0x57) means that window is in disabled state. ## -remarks