Microsoft KB Archive/109363

{|
 * width="100%"|

PRB: Dialog Form Reopened by OpenForm Is Disabled
'Article ID: Q109363

Creation Date: 02-JAN-1994

Revision Date: 19-SEP-1996' The information in this article applies to:


 * Microsoft Access versions 1.0, 1.1, 2.0, 7.0

SYMPTOMS

Moderate: Requires basic macro, coding, and interoperability skills.

When you perform an OpenForm action on a form that was previously opened as a dialog form, the form opens and is selected, but it is disabled.

CAUSE

When an OpenForm action is performed on a form that has already been opened, Microsoft Access opens the form and selects it, even if the form is disabled. The form will not be enabled until other modal forms opened earlier are either hidden or closed.

STATUS

This behavior is by design.

MORE INFORMATION

Steps to Reproduce Behavior

1. Create the following new macro and save it as Macro1:

Actions      Arguments -      Openform      Form Name: Form2 Window Mode: Dialog

2. Create another new macro as follows. Save the macro as Macro2:

Actions      Arguments -      Openform      Form Name: Form1 Window Mode: Dialog

3. Create a new, blank form.

4. Add a button control to the form.

5. Set the button's OnClick property to Macro1.

NOTE: In Microsoft Access version 1.x, the OnClick property is   called the OnPush property.

6. Save the form as Form1.

7. Create another new, blank form.

8. Add a button control to the form.

9. Set the button's OnClick property to Macro2.

Save the form as Form2.

Click the button on Form1 to run Macro1. Note that Form2 opens as   a modal form.

Click the button on Form2 to run Macro2. Note that Form1 opens as   a modal form.

Position Form1 so that you can see both Form1 and Form2.

Click the button on Form1. Note that Form2 is selected, as it should be, but that it is disabled.
 * }

-

"THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED 'AS IS' WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY." '' ©1997 Microsoft Corporation. All rights reserved. Legal Notices.

''

Additional reference words: 1.00 1.10 2.00 7.00

KBCategory: kbusage

KBSubcategory: FmsOthr