Adding a new item to the Cell shortcut menu : Menu « Application « VBA / Excel / Access / Word

VBA / Excel / Access / Word
1. Access
2. Application
3. Data Type
4. Data Type Functions
5. Date Functions
6. Excel
7. File Path
8. Forms
9. Language Basics
10. Math Functions
11. Outlook
12. PowerPoint
13. String Functions
14. Windows API
15. Word
16. XML
Java
Java Tutorial
Java Source Code / Java Documentation
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
VBA / Excel / Access / Word » Application » Menu 
Adding a new item to the Cell shortcut menu
 
Sub AddToShortCut()
    Dim Bar As CommandBar
    Dim NewControl As CommandBarButton
    DeleteFromShortcut
    Set Bar = Application.CommandBars("Cell")
    Set NewControl = Bar.Controls.Add(Type:=msoControlButton, ID:=1,temporary:=True)
    With NewControl
        .Caption = "&Change Case"
        .OnAction = "ChangeCase"
        .Style = msoButtonIconAndCaption
    End With
End Sub

 
Related examples in the same category
1. Creating a Menu Bar
2. Add a new menubar with toggle action
3. Controling a CommandBarControl's Visibility
4. Deletes a control tagged "MyMenu2"
5. Create Submenus
6. Adds button, combobox, text box and drop down to tools menu
7. List Menu Information
8. List ShortCut Menus
9. Adding and deleting menus automatically
10. Disabling or hiding menus
11. Working with checked menu items
12. Disabling a shortcut menu
13. Enables the shortcut menu when the workbook is closed.
14. Create a new menu bar that replaces the existing menu bar
15. Adding a menu: Take 1
16. Adding the Budgeting menu to Excel's main menu bar
17. Determined the Id property of the Help menu by executing the following statement:
18. Deleting a menu from a menu bar
19. Adding selections and submenu items to the Budgeting menu
20. Adding a selection to Excel's Tools menu
21. Deleting a menu item from the Tools menu
22. Adding a menu selection that features a shortcut key
23. Adding menu items to shortcut menus
24. Deleting menu items from shortcut menus
25. removes the Hide menu item from two shortcut menus: the one that appears when you right-click a row header and the one that appears for a column header.
26. Disabling shortcut menu items
27. Disabling shortcut menus
28. If you want to disable all shortcut menus, use the following procedure:
29. Resetting shortcut menus: The Reset method restores a shortcut menu to its original condition.
30. Creating an entirely new and separate shortcut menu
31. Create a popup menu
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.