ACC2: Application Hangs Using COMMDLG.DLLLast reviewed: May 14, 1997Article ID: Q124903 |
The information in this article applies to:
SYMPTOMSAdvanced: Requires expert coding, interoperability, and multiuser skills. An application stops responding (hangs) when you try to close it after the application displays the common Open File dialog box from COMMDLG.DLL. For example, the AreTablesAttached() function in the Solutions sample application (SOLUTION.MDB) exhibits this behavior if you click anywhere outside the "Where is NWIND?" common dialog box and then try to quit the Solutions sample application or Microsoft Access without first closing the common dialog box.
CAUSEThis problem occurs when you fail to set the hWnd member of the OpenFileName structure passed to the GetOpenFileName() function in COMMDLG.DLL.
RESOLUTIONMake sure that the parent window's handle is passed in the hWnd member of the OpenFileName structure. If the proper handle is passed in the structure, the common dialog box will be opened as a modal dialog box and users will not be able to close the parent window without first closing the common dialog box.
STATUSMicrosoft has confirmed this to be a problem in Microsoft Access version 2.0. This problem no longer occurs in Microsoft Access version 7.0.
MORE INFORMATION
Steps to Reproduce ProblemThese steps assumes that you are familiar with Access Basic and with creating Microsoft Access applications using the programming tools provided with Microsoft Access. For more information on Access Basic, please refer to the "Building Applications" manual. WARNING: The following steps will cause Microsoft Access to hang, forcing you to restart Windows. Make sure to save and close any open work on your computer before following these steps.
Steps to Correct Problem in SOLUTION.MDB
REFERENCES"Microsoft Windows 3.1 Programmer's Reference," Volume 1, Chapter 4, "Common Dialog Box Library" |
Keywords : DcmSltn kbusage
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |