DefWindowProcW function

Calls the default window procedure to provide default processing for any window messages that an application does not process. This function ensures that every message is processed. DefWindowProc is called with the same parameters received by the window procedure.

Syntax

LRESULT LRESULT DefWindowProcW(
  HWND   hWnd,
  UINT   Msg,
  WPARAM wParam,
  LPARAM lParam
);

Parameters

hWnd

Type: HWND

A handle to the window procedure that received the message.

Msg

Type: UINT

The message.

wParam

Type: WPARAM

Additional message information. The content of this parameter depends on the value of the Msg parameter.

lParam

Type: LPARAM

Additional message information. The content of this parameter depends on the value of the Msg parameter.

Return value

Type: LRESULT

The return value is the result of the message processing and depends on the message.

Remarks

Note

The winuser.h header defines DefWindowProc as an alias which automatically selects the ANSI or Unicode version of this function based on the definition of the UNICODE preprocessor constant. Mixing usage of the encoding-neutral alias with code that not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.

Requirements

   
Minimum supported client Windows 2000 Professional [desktop apps only]
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header winuser.h (include Windows.h)
Library User32.lib
DLL User32.dll

See also

CallWindowProc

Conceptual

DefDlgProc

Reference

Window Procedures

WindowProc