+ Reply to Thread
Results 1 to 8 of 8

Running a Macro from a button on the Home Tab

  1. #1
    Registered User
    Join Date
    06-18-2012
    Location
    Mountain View, CA
    MS-Off Ver
    Excel 2007
    Posts
    9

    Running a Macro from a button on the Home Tab

    Hey everyone,

    I am going to be passing off a somewhat simple monthly task to someone else after I finish my internship. The person I am passing this off to isn't very Excel savvy, and so I want to make it as easy for them as possible. The monthly task is already solved with a macro that I've written.

    What I need help with is this: I want to put a button on the Home Tab that would run the macro that I've written. Any help would be appreciated!

    Thanks!

    Josh

  2. #2
    Registered User
    Join Date
    07-12-2012
    Location
    New Hampshire, United States
    MS-Off Ver
    Excel 2010
    Posts
    80

    Re: Running a Macro from a button on the Home Tab

    On the "Developer" tab on the top click "Insert" then button. Click to place the button, and then right click it and click "Assign Macro." Choose your macro. If the you don't see the developer tab go to file, options, customize ribbon, and check the box next to Developer. Let me know if it works.

  3. #3
    Registered User
    Join Date
    06-18-2012
    Location
    Mountain View, CA
    MS-Off Ver
    Excel 2007
    Posts
    9

    Re: Running a Macro from a button on the Home Tab

    That works makes my macro run, but I would prefer to have it in the ribbon bar above the cells with all my data. Do you know how to add a button on the ribbon?

  4. #4
    Registered User
    Join Date
    07-12-2012
    Location
    New Hampshire, United States
    MS-Off Ver
    Excel 2010
    Posts
    80

    Re: Running a Macro from a button on the Home Tab

    Go to File, Options, Customize Ribbon, New Tab. From the drop down at the top left titled "Choose commands from:" select macros. Click on the "New Group (Custom)" you just created when clicking New Tab, then select your macro from the left and click "Add > >" you may also rename the tab by right clicking on "New Tab (Custom)" and clicking Rename. To run the macro just click on the tab on the top and click on the macro.

    Alternatively:

    You may assign a hot key to your macro. Click the "Developer" tab on the top then click "Macros" on the far left in the "Code" section. Choose your macro from the list and click "Options" and enter the hotkey you want. If, for example, you want to use s but do not want to overwrite the ctrl+s for save, instead of typing a single letter you may hold shift and press a letter, thus making the hotkey ctrl+shift+s.
    Last edited by carrob; 07-31-2012 at 02:42 PM.

  5. #5
    Registered User
    Join Date
    07-12-2012
    Location
    New Hampshire, United States
    MS-Off Ver
    Excel 2010
    Posts
    80

    Re: Running a Macro from a button on the Home Tab

    If you want it on an existing tab you can click on a tab and hit "New Group" , then choose macros from the drop down "Choose commands from" and add your macro to that group. Macros can only be added to custom groups.

  6. #6
    Registered User
    Join Date
    06-18-2012
    Location
    Mountain View, CA
    MS-Off Ver
    Excel 2007
    Posts
    9

    Re: Running a Macro from a button on the Home Tab

    Thanks! I think I'll just go with the short cut key option. It's very simple and should be easy for him to remember.

  7. #7
    Registered User
    Join Date
    07-12-2012
    Location
    New Hampshire, United States
    MS-Off Ver
    Excel 2010
    Posts
    80

    Re: Running a Macro from a button on the Home Tab

    Glad it works, dont forget to mark the thread as solved. to do this click on "Thread Tools" at the top and click "Mark as Solved."

  8. #8
    Forum Expert Cutter's Avatar
    Join Date
    05-24-2004
    Location
    Ontario,Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,451

    Re: Running a Macro from a button on the Home Tab

    @ josh.metherd

    Based on your last post it seems that you are satisfied with the solution(s) you've received but you haven't marked your thread as SOLVED. I'll do that for you now but please keep in mind for your future threads that Rule #9 requires you to do that yourself. If your problem has not been solved you can use Thread Tools (located above your first post) and choose "Mark this thread as unsolved".
    Thanks.

    Also, as a relatively new member of the forum, you may not be aware that you can thank those who have helped you by clicking the small star icon located in the lower left corner of the post in which the help was given. By doing so you can add to the reputation(s) of those who helped.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1