DefDlgProc

Version 3.0

Syntax

LONG DefDlgProc(hDlg,wMsg,wParam,lParam)

This function provides default processing for any Windows messages that a dialog box with a private window class does not process.

All window messages that are not explicitly processed by the window function must be passed to the DefDlgProc function, not the DefWindowProc function. This ensures that all messages not handled by their private window procedure will be handled properly.

Parameter Type/Description  

hDlg HWND Identifies the dialog box.  
wMsg WORD Specifies the message number.  
wParam WORD Specifies 16 bits of additional message-dependent information.  
lParam DWORD Specifies 32 bits of additional message-dependent information.  

Return Value

The return value specifies the result of the message processing and depends on the actual message sent.

Comments

The source code for the DefDlgProc function is provided on the SDK disks.

An application creates a dialog box by calling one of the following functions:

Function Description

CreateDialog Creates a modeless dialog box.
CreateDialogIndirect Creates a modeless dialog box.
CreateDialogIndirectParam, Creates a modeless dialog box and passes data to it when it is created.  
CreateDialogParam Creates a modeless dialog box and passes data to it when it is created.
DialogBox Creates a modal dialog box.
DialogBoxIndirect Creates a modal dialog box.
DialogBoxIndirectParam Creates a modal dialog box and passes data to it when it is created.
DialogBoxParam Creates a modal dialog box and passes data to it when it is created.