Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Programmatically call a menu item from a menu from a Add-in
I have the Hyperion Smart View add-in in my Excel. I tried to add a command
button which basically will call a command item on this Hyperion menu. When I used the Application.CommandBars("Hyperion").Controls("Memb er Select...").Execute in the VBA code, it does not work. The error message is "Runtime error 5: invalid procedure call or argument". If I call an Excel standard menu item, it works fine. Does anyone know how to programmatically call a non-Excel standard menu item that comes from a third-party add-in? Thanks a lot in advance! |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Programmatically call a menu item from a menu from a Add-in
Try this version (assumes the Hyperion control is on the Excel menu bar)...
Application.CommandBars(1).Controls("Hyperion").Co ntrols("Member Select...").Execute If the above doesn't work then it probably means that the Member Select item contains additional controls and you will have to choose one... Application.CommandBars(1).Controls("Hyperion") _ ..Controls("Member Select...").Controls("Sludge").Execute -- Jim Cone Portland, Oregon USA http://www.realezsites.com/bus/primitivesoftware (Excel Add-ins / Excel Programming) "Thomas" wrote in message I have the Hyperion Smart View add-in in my Excel. I tried to add a command button which basically will call a command item on this Hyperion menu. When I used the Application.CommandBars("Hyperion").Controls("Memb er Select...").Execute in the VBA code, it does not work. The error message is "Runtime error 5: invalid procedure call or argument". If I call an Excel standard menu item, it works fine. Does anyone know how to programmatically call a non-Excel standard menu item that comes from a third-party add-in? Thanks a lot in advance! |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Programmatically call a menu item from a menu from a Add-in
Wow, that works. It seems that for non-Excel standard, I should use this
syntax. Thanks a lot for the quick help! Thomas "Jim Cone" wrote: Try this version (assumes the Hyperion control is on the Excel menu bar)... Application.CommandBars(1).Controls("Hyperion").Co ntrols("Member Select...").Execute If the above doesn't work then it probably means that the Member Select item contains additional controls and you will have to choose one... Application.CommandBars(1).Controls("Hyperion") _ ..Controls("Member Select...").Controls("Sludge").Execute -- Jim Cone Portland, Oregon USA http://www.realezsites.com/bus/primitivesoftware (Excel Add-ins / Excel Programming) "Thomas" wrote in message I have the Hyperion Smart View add-in in my Excel. I tried to add a command button which basically will call a command item on this Hyperion menu. When I used the Application.CommandBars("Hyperion").Controls("Memb er Select...").Execute in the VBA code, it does not work. The error message is "Runtime error 5: invalid procedure call or argument". If I call an Excel standard menu item, it works fine. Does anyone know how to programmatically call a non-Excel standard menu item that comes from a third-party add-in? Thanks a lot in advance! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
VBA:programmatically invoking menu items from Excel Worksheet menu | Excel Programming | |||
Call a menu item | Excel Programming | |||
Adding Sub Menu Item to Current Custom Menu | Excel Programming | |||
Menu items added with menu item editor in older versions | Excel Discussion (Misc queries) | |||
Adding a menu item right click menu when clicking on a single. | Excel Programming |