MenuRighter

MenuRighter – Excel 2010 and Later

MenuRighter is an Excel addin that lets you modify right-click menus. You can add almost any control found in other right-click menus or Excel 2003’s “classic” menus – such as the Edit menu, Freeze Panes button, and even your own addin menus. You can also rearrange right-click menus, delete buttons, or move buttons up from a sub-menu. For example you can copy “Filter by Selected Cell’s value” to the root level of the Cell context menu. The download on this page is compatible with both 64-bit and 32-bit versions of Excel.

NOTE: An update on 8/4/2018 corrected a bug that was preventing changes to newer controls, such as Translate.

Download the MenuRighter 2010-2016 addin

MenuRighter lets you search through right-click menus such as Cell, Drawing Objects, and Pivot Table, along with Excel 2003 top-level menus like File and Edit, plus any custom commandbars you’ve created. You can then insert them into almost any right-click menu. Here’s a quick example, where the Freeze Panes command is added to the Row menu and its Cut, Copy and Paste buttons are deleted:

row freeze panes

I first wrote MenuRighter in December 2011 and it’s been downloaded a couple of times a day since then. The original version relied more on users knowing where commands were located in Excel 2003. This current version lets you just search for controls by right-click menu, name, ID or the 2003 menu they were found in. So if you want to add Goal Seek to the cell menu, a quick search is all you need.

This version of MenuRighter works with Excel versions from 2010 and later. (For Excel 2003 and 2007 versions visit the old MenuRighter page.) Here’s how it works:

Why it Works

The ribbon replaced the old Excel 2003 File, Edit, etc., menu structure. But the 2003 menus and controls still exist in the background. The right-click menus in modern Excel versions are still mostly the same structure as in 2003, with new controls added of course. This all means that we can program changes to the right-click menus using the memu system, and that’s why MenuRighter works.

2003_menus

Installing MenuRighter

MenuRighter is an ordinary xlam add-in. If you don’t know how to install add-ins, a quick internet search will get you instructions, such as these from the Contextures website.

Using MenuRighter

Menu Righter Tab
When the MenuRighter xlam is installed in 2010 or later, a new menu group appears in the Developer tab. There is a lone MenuRighter toggle button, which you click to show or hide the MenuRighter form. Here’s how to show the Developer tab.

MenuRighter looks like this:

MenuRighter v2 in repose

The MenuRighter form is resizable. You can drag to resize or use the upper-right corner buttons.

Contextures MenuRighter Introduction Video

Debra Dalgleish published an excellent YouTube video that quickly and clearly outlines the major MenuRighter features. Thanks Debra! I recommend viewing it and then reading below for more details if needed (to skip over the part about how to download, go to 1:30):

The Basics

As you can see above, the source controls are generally on the left. These let you select the commands to add to right-click menus. The target controls are on the right. These let you select the menu to add to, and also to delete and rearrange existing menu buttons.

Source Controls

Let’s look at the Source Controls first:

source controls

At the top are two dropdowns and a search box that let you filter to the menu item you want to add. It starts out filtered to the Excel 2003 Add Command toolbar and its File menu. The listbox contains all the controls found in that menu, e.g., Open, Close and a bunch more.

Let’s say you want to add a Freeze Panes button to the Row menu. Because the search box allows wildcards you don’t need to do anything in the first two boxes. Just type “*freez” in the search box. In the default Excel 2016 setup the listbox will show three instances of Freeze Panes from Excel 2003 toolbars. They’re all the same, so you can select any one:

freeze panes search

You can refine your search by switching the first dropdown from Full Path to one of the other choices, such as “Control Name.” And the second dropdown can be set to “Contains” or “Exactly Matches.” Generally though, you can just use “Full Path” and “Begins With” with an asterisk at the beginning of the search string.

There are four more controls at the right of the Source Control section:

  • The Unique checkbox only applies if you’ve selected Control Name in the first dropdown. It’s on by default and means that only one instance of each control is shown
  • The Add button adds the control to the target toolbar once you’ve selected it. (More on that below.)
  • The Execute button attempts to execute the currently selected command in the list. If it’s not applicable to your current Excel situation it will be disabled, and even if enabled it may not do anything. But if you click it when Add Command;File;Open is selected, for example, you’ll get the File Open dialog.
  • The Show List command shows the entire list of available commands, as currently filtered, in a new worksheet. It’s just a different way to search for menu items to add. If you’re using Excel 2013 or higher, you should close this sheet after you’ve looked at it. (More on that below.)

Semicolon Separator You will notice that I used the semicolon as a separator between menu levels, as in “Add Command;File;Close.” It’s akin to a path separator in Windows. I chose semicolons because they’re not used in menu or control names and it’s in the keyboard home row. You can avoid using them with the judicious use of wildcards, but if you’re typing out a full path you’ll need to include them.

Target Controls

target toolbars

The Target Control section has a dropdown at the top with the names of the shortcut menus (toolbars) that can be modified, such as Cell, Row, and Pivottable Context Menu. Below that is a listbox with all the controls on the selected shortcut menu.

Use the Top, Bottom, Up and Down controls to reposition the currently selected control. The Delete button deletes the currently selected control. Double-clicking also deletes it.

The Rest of the Controls

The mix of functions is a little confusing with these four and I’m not completely satisfied with their captions, but so be it:

  • Reset to Default resets the currently selected target toolbar to its Excel default. This means any changes ever made to the selected shortcut menu will be removed.
  • Show Current pops up the currently selected right-click menu as configured. It won’t show changes you’ve made until you’ve applied them.
  • Clear Changes clears any changes you’ve made to the listbox that haven’t been applied yet.
  • Apply Changes applies the changes you’ve made in the listbox.

Clicking any of these controls pops up the actual target menu, which you can use right away! Or later.

applied changes

One last control, the Show Labels on Menus checkbox, adds a control to each right-click menu with that menu’s name and ID. This is discussed more below.

Putting it all Together

  1. Select a target shortcut menu (toolbar).
  2. Search for and select a source control and add it to the target controls list with the Add button or by double-clicking. The control will be placed above the selected control in the target list. If none is selected it will be added to the beginning.
  3. Repeat step 2 for as many controls as you want to add to the selected target toolbar.
  4. Reposition or delete controls as desired.
  5. Apply the changes to the target toolbar with the Apply Changes button.

If you make changes but don’t apply them, you will be prompted to do so if you switch to another target toolbar or close the form:

unsaved changes

Finding the Name of the Target Toolbar

It may be that you don’t know the name of a right-click menu. For instance, how many people know that the one for a sheet tab is called “Ply”? This is where the “Show Labels on Menus” checkbox helps. When it’s checked every shortcut menu gets an additional control whose caption is that toolbar’s caption and ID. (The ID is useful for distinguishing between the pairs of Row, Column and Cell shortcut menus. There’s one each for Normal View and Page Break View.)

show menu name

Adding Other Addin Controls

You can add controls from custom toolbars or addins as well, as long as those addins create classic menus.

Special Considerations with Excel 2013 and Later

With Excel 2013 came the Single Document Interface. This means that each workbook appears in its own window. I’ve used Jan Karel Pieterse’s code to keep the MenuRighter userform on top in these Excel versions.

There’s a bigger issue though that makes it a little trickier to maintain your MenuRighter changes in Excel 2013 and later. Here’s what I’ve figured out. Excel 2013 and later only recognizes toolbar customizations in the workbook that was open when those changes were made, or in workbooks that were opened after the changes were made. So if you open a workbook, then open another, then open MenuRighter and then close the second workbook you opened, your changes will be lost.

The easy way to deal with this is to open Excel, open a workbook, open MenuRighter and then make your changes. After that just close and re-open Excel and the changes will be permanent.

It works in 64-bit Excel

The heading says it all. The MenuRighter download on this page works in 64-bit and 32-bit Excel.

Miscellaneous

  • MenuRighter doesn’t work on chart context menus, as far as I can tell. These menus are some new kind of beast. They can be modified using Ribbon XML
  • MenuRighter only allows limited edits to the Ply context menu – the one that appears when you right-click a sheet tab. I’m able to add commands from my own addins but rearranging or adding buttons from built-in context menus doesn’t work. The changes show up in MenuRighter after I’ve made them, but they don’t show up in the actual context menu.

Downloads

Download the MenuRighter 2010-2016 addin

If you are looking for versions that work with Excel 2003 and 2007 go to the old MenuRighter page. Those versions have a different interface and all the instructions are there.

68 thoughts on “MenuRighter

    • Hi Mc and Jeff, Sorry, I should have mentioned that on this page. Many addins don’t work in 64-bit Excel, including MenuRighter. There is no 64-bit version. I’ve added this information to this page.

  1. I added and it appears in the developer tabs and works but when I close the file and open new one it is not there anymore please advise how to fix it,

    • Hi Nina, You don’t say what Excel version you’re using, but be sure to check out the “Special Considerations with Excel 2013 and Later” section above, if that applies.

  2. Hi,
    great software and great write up. I have a question though – is it possible to make it so that I can right click a selection of cells and have menurighter do a google search of their contents?

    I appreciate your response and your software. Thank you.

    • Hi David. Thank you. I’m not sure I understand your question. You can’t have “MenuRighter do a google search.” However, if you have a subroutine that does such a search, and you have code that adds the sub to the 2003-style menus, you can use MenuRighter to add a button to the Cell context menu that calls your subroutine.

      That’s a few “ifs” I know. I do the above a lot, but it does require knowing VBA, specifically how to modify the Application.CommandBars collection. Good luck!

  3. Doesn’t work in 64-bit Excel… Ooooohh! Otherwise, the Add-In is awesome. A+.

    Are you working on any date for the 64-bit version?

    Thanks

    Best regards

    Carlos

      • Oh, please do. If it is safe for my computer I will try it and will tell you if it works.

        Thanks in advance Doug!

        Cheers

        Carlos

          • I’m still getting the same error and it looks like the issue in my case was not choosing between 32-bit or 64-bit excel but it is about my excel version being a 2016 one.
            I have sent you an email with some captures of my screen, just for your information.

            Thanks

          • Yes. Now it works. The thing is, excel creates two commands for MenuRighter and two potential fast access toolbar buttons and you must choose only one of these commands (it doesn’t matter which one), if you install both and click any of the two buttons then an error message pops up and MenuRighter doesn’t open. I don’t know why but that’s the way that it is. Problem solved!
            Thanks Doug!

  4. I have Excel 2010. The MenuRighter form shows the Target drop-down just fine. However, it doesn’t have any drop-downs under Source. It has one box that displays the choice that has been double-clicked in a menu below it. No further options are available. For example, the first item on the menu is &Legacy Keyboard Support. Double-clicking it displays “&Legacy Keyboard Support” in the box above the menu (still on the Source side of the form). There are many choices, such as Row (listed twice), Lines, Stop Recording, etc. But no commands are available to choose. What’s wrong?

  5. Is there any way to rename an item in the menu? I figured out that I can use the “Add Command;Macros;Custom Menu Item” to run a macro. I need to add several of these for different Macros. Is there any way to rename them in the menu?

    • Hi Tyler, Yes you can rename them, but it takes VBA. You’d do something like: Application.Commandbars("Cell").Controls("Custom Menu Item").Caption = "New Caption". I don’t know if that will work with more than one control.

      A better way is to make your own 2003-style menu, as in this post: http://www.ozgrid.com/VBA/custom-menus.htm. All of it’s controls will then show up in MenuRighter and you can add them to right-click menus, just like with the built-in ones.

  6. I just installed Office 2013. I can dl the MenuRighter and complete all the tasks in one workbook. Apply changes and it works great.
    However, as soon as I close that workbook, the MenuRighter disappears and all my changes are no longer there.
    Not sure what to do!?!?
    I read above someone had the same comment and I did exactly how it states. Open Excel, open workbook, open menurighter and make changes, close all and it should be permanent but it doesn’t seem to be.
    Can you please help?

    • Hi AnnaLisa, It sounds like you are doing the right thing. To review.

      Open Excel. There should be an open workbook as soon as you open. If not, open one.
      Start MenuRighter
      Make your menu changes, applying them as prompted.
      Close MenuRighter.
      Close Excel.

      If this doesn’t work, I don’t know how to fix it. I suppose you might have another addin or process that resets your menus.

      • I’m having the same issue. 32 bit Office 365 (2016+). The only other add-ins are Solver and Analysis.
        I install your add-in, but every time I close Excel it disappears from the ribbon and I have to disable/re-enable the add-in.
        Even when I follow your instructions above, it “forgets” my changes. I suspect if MR was loading properly each time I open Excel, it would probably be better at remembering the changes.

      • I solved this for me – you should update your instructions:

        From:
        https://superuser.com/questions/1103770/excel-add-ins-not-loading-since-july-2016-office-update

        “This problem results from security patch in KB31152, released in July 2016. According to private communication with Microsoft software engineers:

        “With this update, we changed the behavior of Excel so that it will not load certain file types (including .xlam) when they are untrusted. The easiest workaround is to find the add-in that is causing you trouble, right-clicking on it in Windows Explorer, and checking Unblock””

        Works great now!

  7. Can you please send me the 64-bit version that you sent to Carlos, I am using the latest version of Excel.

    Thanks

    Best regards

    Aziz

  8. Thanks for the link Doug. I have Excel 64bit latest version. I installed it, but the MenuRighter form shows the Source Controls drop-down menu the following options: Full Path, Control Name, Control ID, Parent Menu, Parent Path. In the big box bellow doesn’t show anything, it is blank. I clicked in all the options of the Source Controls and nothing appears in the box bellow. The Target drop-down it just fine it shows options. What can I do?

    Thanks in advance

    Aziz

  9. Hello Doug,

    When I try and apply changes I’m getting
    “Error 6 Overflow in frmMenuRighter:ApplyChanges ”
    That says I have multiple workbooks open , but in fact I only have 1 open.

    Any Ideas on why this may be?

    Thanks for such a great tool you’ve built!!

    • Hi Andres,

      That sounds like two messages, one about a big number and one about having multiple workbooks. Can you give me more detail on what you are doing and what message you get?

      The one about an overflow seems to suggest you have a right-click menu with thousands of items, which seems unlikely. Other than that, I’m not sure.

      • I am getting the same issue. Specifically, I am trying to remove the Translate option when you right click on a cell. (It breaks my hotkeys because it shares s with Paste Special).

        The error message occurs when I try to remove Translate from the Cell (the first one) Toolbar and then click Apply Changes. Specifically, the error says


        Error 6
        Overflow
        in frmMenuRighter:ApplyChanges

        In Excel 2013 or later, it’s best to use MenuRighter with just one workbook open and apply changes with just that workbook open.

        This error happens whenever I attempt to apply any change (removes, move item, …) to that first Cell Toolbar. Oddly, it seems to give me a double-long right click menu with every item repeated twice after trying. Resetting that first Cell toolbar reverts to the old.

        I tried removing Translate from the second Cell Toolbar as well, but it does not remove it when I right click.

        I only have one, blank Excel workbook open while doing this.

        Also thanks. This tool looks awesome and a friend of mine used it to great effect. Hoping for the same.

        • Hi Will,

          It should be fixed now. I reproduced exactly what you described and now it works.

          I had a function that processed the Control IDs and used a VBA function, that only recognizes numbers up to 32,000 or so. Translate’s ID is over 33,000 and so the function failed. I switched to a function that handles bigger numbers, so until we get controls with IDs in the millions it should be safe :).

          I made the change to the “2010 and later” version, which is what I assume you are using. Please let me know if it works now.

          And thanks for letting me know!

    • Hi Arif, You would have to write code that adds them to a commandbar. But did you know you can see all the worksheets in the current workbook by right-clicking the navigation arrows in the bottom-left corner of Excel?

  10. Trying to use your add-in on my 2017 MacBook Pro for Excel 2016 version 16.14.1. I keep running into an error after download, curious if it’s not compatible. Apologies if you included that somewhere on your page already. Any thoughts?

    Error: ” Microsoft Visual Basic: Compile Error: Can’t find project or library”

    It highlights the below text assuming it’s pointing out the problem code:

    Private Sub ResetCboToBars()
    Dim dicCommandBarNames As Scripting.Dictionary

    Any assistance you can provide would be appreciated! Thanks 🙂
    Johanna

    • Hi Johanna, I don’t have any experience with Mac compatibility. I’m curious if you are generally able to use Excel addins on your Mac?

      TLDR: Doesn’t look fixable unless you are willing to do some non-trivial coding.

      I can tell you that, as the message says, it’s looking for the Scripting.Dictionary dll. In Windows that’s a very stable dll that’s been around for a long time in all versions. If that wasn’t the case I would have coded it with “late binding” which doesn’t care which version of the dll is on a computer.

      However, with some googling it looks like the Mac requires a more extensive workaround, e.g., https://stackoverflow.com/questions/19869266/vba-excel-dictionary-on-mac

      And, of course, even if this part works, there may be other errors that pop up as soon as this one is solved.

      Sorry, and good luck! Let me know if you figure our anything.

  11. MenuRighter is awesome. Thank you!
    I would like to know how I can duplicate changes on one PC to Excel 2013 on my laptop. I tried copying Personal.xlsb but did not help.

    • Hi Trevor, Thanks! You can copy the xlb file, which contains the context-menu customizations. I’ve done this between computers, and after Office 365 upgrades, which at least sometimes wipe out all my right-click menu changes.

      The xlb file doesn’t contain much, if anything, besides this info, so should be safe, but back it up first. I’m also not clear if you are going between Excel versions, and can’t remember if that works. I think it might.

      You’ll find the xlb file in the same folder that contains the XLSTART folder. On my computer it’s at “C:\Users\doug\AppData\Roaming\Microsoft\Excel\Excel15.xlb”. The 15 refers to Excel 2016, so yours will be 14, I think.

      Let me know if that works.

  12. Hi Doug, read the caution about not being able to change PTY menu.I wanted to add an “Open in new window” option to sheet tab right-click menu. Saw that you said that this was not possible but that menu options from an addin worked. However although I created an addin for this, I cannot see how to view/get this option at left side to add to pty menu.

    • Hi Trevor. Your addin has to create classic menu items, since that’s what MenuRighter works with. So if your addin creates a menu that shows up in the Addins tab of the modern Excel ribbon, you’ll be able to access those with MenuRighter.

      However, it’s not that easy to find code any more for modifying the classic menu system. Spending ten minutes the best example I can find is https://www.mrexcel.com/forum/excel-questions/916765-application-commandbars-worksheet-menu-bar-buttons-first-submenu-last.html

      • Thanks again for your fast response! I managed to create an Excel file based on the reference you gave and, saved as an addin, it worked. However when I then referenced that command in menurighter, the result was that when I right clicked on a worksheet tab and selected that command, it opened as many new windows as there were worksheets in the Excel file. I suspect this may have something to do with the main top command bar applying to all worksheets.

        Looking further through this thread, I saw your reference to OZGRID menu changes and looked at that. This enabled me to create a macro based on the code shown there, much simplified and “Cell” replaced by “PLY” and then activated by the worksheet-open event and saved in the personal file. This works a treat!

        • Forgot to say that I’ve found that Menurighter can be deselected as an add-in once the menus have been changed. This makes quite a difference to the loading time of Excel. Maybe that was in the original documentation and I missed it but could be useful to other readers.

          • Update on this: latest version of Office 365 (insider version) seems to block the action of new window from sheet tab (PLY menu) saying macro Nwindo not available. However it is there and will run drom the macros tab in ribbon. However I found a work-around: I have a separate addin for a function I defines and added the simple nwindo macro to that. Now Menurighter added right click on sheet tab works! Might be a handy solution to other “PLY” difficulties.

             Sub Nwindo()
            'General macro to duplicate windowe view
                ActiveWindow.NewWindow
            End Sub
        • That’s great Trevor. Good work figuring all that out. The ply menu is a bit mysterious. Have you noticed that menu writer has a feature for showing you the names and numbers of menus as you use them?

          • I had not seen that but checked it out. See 41-ply and 35-cell on right clicking sheet tab and cell as test. Will keep in mind for future use.

  13. Hi Doug. First of all thanks a LOT for making this addin. I must be doing something wrong here. The addin works fine to start with, I customize everything under its ActiveX Control menu and then apply the changes. But I can’t for the life of me see any changes appear whatsoever when I right-click, let alone stick after an Excel restart. I did unblock the addin at the file property level. I am running the 32-bit version of Excel 2016 Professional version 1907.

  14. MenuRighter works great in Excel 2016, but I don’t “see” the Add-In item I want to move in the cell contextual menu. The Add-in item is currently at the top of the contextual menu and I want to move it to the bottom. Is this expected behaviour? The Add-in that does not show up in MenuRighter is also a .xlam file. I want to move the Add-on selection to the bottom of the cell context menu as I need it a lot but have to scroll up the context menu to select it every time. I did identify the right cell context menu by checking “show labels on menus”..

    • Taber, I’m not sure I understand the issues. MenuRighter accesses menu items using the CommandBar and related objects in VBA. So, if you added the menu item to the Cell menu with code like Commandbars(“Cell”).Add, then I would expect you to see it in MenuRighter. If you added it with XML/Ribbon then it won’t be accessible to MenuRighter.

  15. Hello S Johnson. You’re right. Paste as Picture is a newer type of control that’s not supported by MenuRighter. MenuRighter supports buttons that used to appear in Excel 2003-type menus. So, it’s kind of amazing it still works at all!

    It does support sub-menu buttons if they are regular button, like those in Cell > Filter or Cell > Sort.

    The only option I know is to create an addin that creates a button that calls the Paste as Picture command using

    Application.Commandbars.ExecuteMso("PasteAsPicture")

    . You can then use MenuRighter to add that button wherever you want.

    • Hi Andre, there are instructions for making it work in the post, and I think in the tool. Basically, open Excel, open workbook, make your changes, close Excel.

      If you’ve already tried that, and it’s not sticking, I’m not sure what the issue is. Good luck!

  16. I have custom context menu item (macro) that I can easily move to the top of the right-click menu. However, after closing and reopening my file, it reverts to putting my custom menu item back to the bottom. How do I get it to retain the order?

    Office 365 32-bit running on Windows 10 Pro 64-bit.

  17. Hi Doug,
    Super cool Add-in 🙂
    I have used it for long with Excel 2010.

    Is it also working with Excel 2019 ?
    After making changes and close/reopen Excel (2019 ver.32bit) it seems to loose them.
    thanks,
    Mark

  18. Hello, Do you know of any products that allow the VBA editor toolbars to be customized, exported, imported, etc… It seems every time I start the editor the toolbars are in different locations and sometimes even gone. Any help or advise would be appreciated.

  19. menurighter menu update not saving in excel 2019; I added a print function to the cell context menu (right click menu) and saved it. Closed the file and re-opened it and it did not save. A also tried doing the same thing with a new spreadsheet file and it didn’t save. I selected the item and the menu, clicked apply, and it showed up in the menu , then I saved it. Is there a work around? Thanks.

  20. Tried menuwrighter on excel 2019 and it would not save the context menu revision. Do you have a work around. Tried on existing spreadsheet, and a new file.

Speak Your Mind

Your email address will not be published. Required fields are marked *

To post code, do this: <code> your vba here </code>