This function enables a language that cannot support window procedures to provide the function of a modal dialog. The application creates a modeless dialog by the use of the WinCreateDlg or the WinLoadDlg functions and then issues this call to process messages only associated with the dialog.

The first time that this function is issued, the owner of the window specified by hwndDlg is disabled, thereby preventing input into windows other than the dialog. The owner of the window specified by hwndDlg is enabled when the WinDismissDlg function is issued either by the application or by the default dialog procedure.

If a WM_QUIT is encountered, WinGetDlgMsg itself issues a WinDismissDlg function, and posts the WM_QUIT message back to the queue so that the application main loop terminates in the normal way.


[Back] [Next]