SAMPLE: Code Demonstrates Creating Dialog Box in DLLLast reviewed: February 15, 1996Article ID: Q82170 |
The information in this article applies to:
DLLDLG is a file in the Microsoft Software Library that demonstrates creating a dialog box in a dynamic-link library (DLL). The DLL contains a routine that calls the DialogBox function. After the user types some text into an edit control in the dialog box and chooses the OK button, the routine calls the MessageBox() function to display the text. Because a DLL has only one instance, it is not necessary to call the MakeProcInstance() function for the dialog box procedure. The DLLDLG sample demonstrates this by specifying the dialog box procedure's name in the call to the DialogBox() function. The DialogBox() function uses the value of its hInstance parameter to locate the dialog box's resource template. For this reason, the hInstance value must point to the module that contains the template. For the DLLDLG sample, the hInstance value passed to the DialogBox() function is the value of the hInstance parameter passed to LibMain(). Download DLLDLG.EXE, a self-extracting file, from the Microsoft Software Library (MSL) on the following services:
|
Additional reference words: 3.00 3.10 softlib DLLDLG.EXE
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |