Mirosoft Excel Menu Animations

Posted on 2007-10-19
Last Modified: 2012-06-27
Mircosoft Excel VBA Editor.
I have added a menu called "Build Tools" to the default Excel Command Bar using the VB Editor.  On the
drop down there are four options that will each run a separate macro.  What I require is code or method
to provide an animation in the space provided - something similar to the Copy and Paste items.
Question by:jguerin2

    Expert Comment

    could you record a macro doing the copy paste actions then analyse the VB code and see how its been done?
    LVL 80

    Expert Comment

    Ivan Moala explains how to do animations using a successive series of images in this web page (and its follow-on links):

    Note: the demonstration & code on the follow-on page renders poorly in Firefox. It looks much better in Internet Explorer.

    Author Comment

    Thanks for the answers but none of these suffice - i just need simple code to add an animation to the drop down menu.  So when I click on my Build Tools menu my drop down should resemble the drop down when clicking for example file - static "JPEG" next to Open,New,Save etc - I hope I am making this a bit clearer - thanks for help so far
    LVL 80

    Accepted Solution

    If you want an icon next to the menu item, then by far the easiest approach is to use one of the built-in icons furnished with Office. You do this with the FaceID property of the command bar control. John Walkenbach provides a means of seeing all the possibilities in

    Assuming that you know the desired FaceID, you would assign it to your control with:
    Application.CommandBars("Build Tools").Controls("Do stuff").FaceID = 52     'Assign "piggy bank" icon to this control
    Application.CommandBars("Build Tools").Controls("Do stuff").Style = msoButtonIconAndCaption     'Display both text and icon


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Highfive + Dolby Voice = No More Audio Complaints!

    Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

    A little background as to how I came to I design this code: Around 5 years ago I designed an add-in that formatted Excel files to a corporate standard, applying different cell colours and font type depending on whether the cells contained inputs,…
    Can I legally transfer my OEM version of Windows to another PC?  (AKA - Can I put a new systemboard in my OEM PC?) Few of us are both IT and legal experts but we all have our own views of Microsoft's licensing rules and how they apply.  There are…
    This Micro Tutorial will demonstrate in Google Sheets how to use the HYPERLINK function to create live links inside your spreadsheet.
    This Micro Tutorial will demonstrate in Microsoft Excel how to add style and sexy appeal to horizontal bar charts.

    758 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    10 Experts available now in Live!

    Get 1:1 Help Now