Skip to content

Latest commit

 

History

History
90 lines (55 loc) · 1.97 KB

wm-killfocus.md

File metadata and controls

90 lines (55 loc) · 1.97 KB
title description ms.assetid keywords topic_type api_name api_location api_type ms.topic ms.date
WM_KILLFOCUS message (Winuser.h)
Sent to a window immediately before it loses the keyboard focus.
6d32a09b-a856-4f94-9544-3345b3a700f4
WM_KILLFOCUS message Keyboard and Mouse Input
apiref
WM_KILLFOCUS
Winuser.h
HeaderDef
reference
05/31/2018

WM_KILLFOCUS message

Sent to a window immediately before it loses the keyboard focus.

#define WM_KILLFOCUS                    0x0008

Parameters

wParam

A handle to the window that receives the keyboard focus. This parameter can be NULL.

lParam

This parameter is not used.

Return value

An application should return zero if it processes this message.

Remarks

If an application is displaying a caret, the caret should be destroyed at this point.

While processing this message, do not make any function calls that display or activate a window. This causes the thread to yield control and can cause the application to stop responding to messages. For more information, see Message Deadlocks.

Requirements

Requirement Value
Minimum supported client
Windows 2000 Professional [desktop apps only]
Minimum supported server
Windows 2000 Server [desktop apps only]
Header
Winuser.h (include Windows.h)

See also

Reference

SetFocus

WM_SETFOCUS

Conceptual

Keyboard Input