ACC: Cannot Add Security Items to Custom MenuLast reviewed: May 28, 1997Article ID: Q103992 |
The information in this article applies to:
SYMPTOMSAdvanced: Requires expert coding, interoperability, and multiuser skills. If you add a security command to a custom menu with a DoMenuItem action, the security command will be unavailable.
CAUSEYou can only perform DoMenuItem actions with commands available from the current context. If you have a form open, you can only perform menu items available to a form. Since security items are available only from the Database window, they will not work when invoked from a form.
RESOLUTIONYou can add the security command Change Password to a custom menu using the following sample macro:
Macro Name Action Defined Below
----------------------------------------------
Change Password Echo 1
SelectObject 2
DoMenuItem 3
DoMenuItem 4
SelectObject 5
Change Password Actions
---------------------------------------------------------
1. Echo
Echo On: No
2. SelectObject
Object Type: Form
Object Name: <name of the form that the menu is on>
In Database window: Yes
3. DoMenuItem
Menu Bar: Database
Menu Name: Security
Command: Change Password
4. DoMenuItem
Menu Bar: Database
Menu Name: Window
Command: Hide
5. SelectObject
Object Type: Form
Object Name: <name of the form that the menu is on>
In Database window: No
NOTE: Actions 1 and 5 are used if you need to have the Database window
hidden while using the retail version of Microsoft Access. The Echo
action in step 1 ensures that the Database window is not visible when it
is activated in step 2. Step 4 hides the Database window again. If you
are using the Microsoft Access Distribution Kit (ADK), steps 1 and 5 can
be omitted since the Database window is always hidden.
The only side effect to this workaround is that when the Change Password dialog box appears, you will see the Database window menu items in the background. However, you will not be able to choose them.
STATUSThis behavior no longer occurs in Microsoft Access version 7.0.
MORE INFORMATION
Steps to Reproduce Behavior
|
Keywords : kbusage McrOthr
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |