How to put a custom macro on quick access tool bar

I have created a simple macro to insert the filename and path in a document.  I'd like to put the macro on the quick access toolbar (QAT), but when I go the customize the QAT, I can't find my custom macro in Macros list displayed from the "Choose commands from" drop-down menu, only those that are supplied with Word 2010.  How do I get the custom macro on the toolbar?

I'm using Word 2010, Windows 7 on a PC.  I am not very experienced at all in the creation or use of macros.

Thanks.

Where did you create the Macro.  If it was in the Normal.dotm template or in a template that you save in the Word Startup Folder, it will appear in the list of macros when you select Macros in the Choose commands from drop down when customizing the QAT.
Hope this helps,
Doug Robbins - MVP Office Apps & Services (Word)
dougrobbinsmvp@gmail.com
It's time to replace ‘Diversity, Equity & Inclusion’ with ‘Excellence, Opportunity & Civility’ - V Ramaswamy

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

How do I find out where the macro is stored?  As I said, I'm very much a novice in the use of macros.

Thanks.

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

If you do not know, it is stored in the NewMacros module of the Normal.dotm template. That is where recorded macros are stored unless the user acts to save them elsewhere.

Are you sure you've chosen macros as the command type? There are no macros that I know of distributed with Word. Your macro should be there with the name you gave it.

Modifying the QAT and Ribbon in Microsoft Word

You can use the Visual Basic Editor to look for your macro. Alt+F11.

Again, it would be in the "NewMacros" module of Normal.

Volunteering to "pay forward" the help I've received in the Microsoft user community.


Charles Kenyon
Sun Prairie, Wisconsin
wordfaq[at]addbalance[dot]com

Legal site: https://addbalance.com

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

When I go the the Macros list in the "Choose Commands from" menu, I see this:

Why doesn't my custom macro display in this list?

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

It is displayed. If it is not one of the two in Normal.NewMacros, then it's one of the long list in TemplateProject.NewMacros. Unfortunately, the display can't be scrolled to allow you to see which of these is the one you're wanting to add to the QAT, so you may have to resort to trial and error. Is your macro not the "Filename" one shown in the current QAT list?

More to the point, why do you need a macro to insert the filename and path? This is a simple field, { FILENAME \p }, which you can easily save as an AutoText entry.

  1. Press Ctrl+F9 to insert field braces.
  2. Between the braces, type FILENAME \p (or filename \p--the field is not case-sensitive).
  3. F9 to update the field.
  4. Select the field and press Alt+F3.
  5. In the Create New Building Block dialog, type a name for your AutoText entry, such as "Filename and path." Leave the other settings at the default.
  6. Now, when you type the first few letters of "Filename," you will get an AutoComplete suggestion; press Enter or Tab to insert the field.
Microsoft MVP (Word) since 1999
Fairhope, Alabama USA
http://ssbarnhill.com
http://wordfaqs.ssbarnhill.com
Screen shots captured with TechSmith's Snagit

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

As Suzanne has told you, it is almost certainly in the list. The problem is the length of the names.

TemplateProject is a default name for macros in a template other than normal.dotm. Because of the problem figuring out what is what when I have lots of macros, I adopted naming procedures that have short names.

I generally rename projects to at least give a hint as to which template the project is in. I have started using a prefix of prj in project names.

I never keep macros I want to use in the NewMacros module. I create modules that describe the macros that are in the module. My modules generally have a prefix of mod. I guess the standard prefix is bas.

Reddick naming convention Use of naming convention prefixes and suffixes (standard or your own) makes it much easier to find macros and debug code.

Note that the window for adding to the QAT is resizable. When you make it wider, you get more room in the window that shows the names. That may be all you need right now.


Below is a screenshot from the Visual Basic Editor (Alt+F11). It shows some of the same procedures (macros) shown above.

Note, in the bottom right the Name property. This can be changed for modules or projects. I try to set names and locations firmly before attaching any QAT buttons or keyboard shortcuts to a macro.

Modifying the QAT and Ribbon in Microsoft Word

Volunteering to "pay forward" the help I've received in the Microsoft user community.


Charles Kenyon
Sun Prairie, Wisconsin
wordfaq[at]addbalance[dot]com

Legal site: https://addbalance.com

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

 
 

Question Info


Last updated January 26, 2021 Views 1,445 Applies to: