From: Stewart Berman on
I open an Access 2007 database and run code that creates another instance of Access (mappAccess) and
uses it to open another database as currentDB (mappAccess.OpenCurrentDatabase). It is visible on
the desktop. One of the things I need to be able to do as part of the process is to show a custom
shortcut menu, "Custom Menu" from the opened database. This code:
mappAccess.CommandBars("Custom Menu").ShowPopup
Throws:
Automation error
Unspecified error
The error number is -2147467259 or 80004005 in hex.

If I just open the second database in Access and run the above code the popup menu is displayed so
it appears the definition of the popup menu is correct.

Is there anyway to show a popup menu in a database opened in another instance of Access?
From: Stewart Berman on
Bump

Stewart Berman <saberman(a)nospam.nospam> wrote:

>I open an Access 2007 database and run code that creates another instance of Access (mappAccess) and
>uses it to open another database as currentDB (mappAccess.OpenCurrentDatabase). It is visible on
>the desktop. One of the things I need to be able to do as part of the process is to show a custom
>shortcut menu, "Custom Menu" from the opened database. This code:
> mappAccess.CommandBars("Custom Menu").ShowPopup
>Throws:
> Automation error
> Unspecified error
>The error number is -2147467259 or 80004005 in hex.
>
>If I just open the second database in Access and run the above code the popup menu is displayed so
>it appears the definition of the popup menu is correct.
>
>Is there anyway to show a popup menu in a database opened in another instance of Access?