![]() |
|
|
|
#1
|
|||
|
|||
|
Also ... for those users who might have more than one workbook open/running at the same time, you can add to the "Set Shortcut" code line ...
Code:
Sub AddItemShortCutMenu()
Dim Shortcut As CommandBar
Dim NewItem As CommandBarButton
Set Shortcut = ThisWorkbook.Application.CommandBars("Cell")
Set NewItem = Shortcut.Controls.Add(Type:=msoControlButton)
With NewItem
.Caption = "Custom Action"
.OnAction = "CustomSubroutine" 'The subroutine must be located in Module1 for some reason
End With
End Sub
|
|
#2
|
|||
|
|||
|
That's better - a solution, not just a work-around. Thanks!
|
|
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Context Menu Unavailable | Project Pro | Team Planner View | JKIT | Project | 0 | 12-14-2020 11:28 AM |
| Remove new macros menu item | aufet | Word VBA | 1 | 11-08-2019 05:44 PM |
| Powerpoint 2016 RC context menu after update | AdamC | PowerPoint | 0 | 06-26-2017 11:12 AM |
| Modify right-click context menu to only allow pasting text | derajlance | Word VBA | 0 | 05-24-2016 02:25 PM |
| Call for votes: office 2013 Autocorrect & right click (context menu) | franklekens | Word | 0 | 09-20-2013 12:09 AM |