+ Reply to Thread
Results 1 to 3 of 3

Macro for Using a Sheet tab as a Button

  1. #1
    Registered User
    Join Date
    05-24-2012
    Location
    Italy
    MS-Off Ver
    Excel 2007
    Posts
    2

    Macro for Using a Sheet tab as a Button

    Hi All,

    I found the following article below:

    http://www.experts-exchange.com/Soft...ry-Sheets.html

    The article shows how to use a sheet tab as a macro, to show and hide other excel sheets. Unfortunately i'm new to VBA and programming, but i would like to tailor the coding for my spreadsheet.

    I attach an example of how my spreadsheet looks and what i am trying to achieve.

    When I click the tab "Show Workings a to c", only the sheets a, b and c become visible, and the previous tab changes to "Hide Workings a to c". Upon clicking "Hide Workings a to c", the sheets a, b, and c are hidden.

    When i click the tab "Show workings d to f", only the sheets d, e and f become visible, and the previous tab changes to "Hide Workings d to f". Upon clicking "Hide Workings d to f", the sheets d, e, and f are hidden.

    The other sheets, "index" and "table" remain visible the whole time.

    I've had a go at trying to enter the code myself. I am able to get it to work for the "Show workings a to c" button. But when i try to do the same for the "Show workings d to f" I am unable to get both to work as expected. I think I need to tailor the macro i have entered to be more specific. Would anyone be able to help me in tailoring these macros?

    I attach the file below.

    Example.xlsm

    Thanks for your help in advance.

  2. #2
    Valued Forum Contributor
    Join Date
    02-09-2012
    Location
    Mauritius
    MS-Off Ver
    Excel 2007
    Posts
    1,055

    Re: Macro for Using a Sheet tab as a Button

    Hi

    Try this:

    Example.xlsm
    Click *, if my suggestion helps you. Have a good day!!

  3. #3
    Registered User
    Join Date
    05-24-2012
    Location
    Italy
    MS-Off Ver
    Excel 2007
    Posts
    2

    Re: Macro for Using a Sheet tab as a Button

    Brilliant. Thanks very much for your help. All working perfectly.

+ 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