+ Reply to Thread
Results 1 to 4 of 4

apply macro to several tabs (variable)

  1. #1
    Registered User
    Join Date
    12-17-2013
    Location
    texas
    MS-Off Ver
    Excel 2010
    Posts
    3

    apply macro to several tabs (variable)

    This feels like it should be so easy but it has befuddled me the past two days. I have a pretty lengthy macro in process that takes a data set in a workbook and splices it into several new tabs that vary in number and name. The last piece I'm trying to conquer to this macro is to find all the tabs with specific text in their names and perform some simple actions on all those tabs only (delete row 1 and columns A-C on each, remove all shading, and then format each sheet entirely as General).

    I may or may not be able to use the Dim coding (at least, I got compilation errors when I did) as I have that already in the macro, so as a workaround I tried to make the macro look for the first tab containing the specific text and then doing my required actions on that tab and all that follow (as they are always going to be the final x number of tabs in the workbook), but I can't get that to work, either.

    Any insight would be greatly appreciated. I'm not an expert on this, but I'm not totally ridiculous either.
    thx much.

  2. #2
    Valued Forum Contributor
    Join Date
    09-19-2008
    Location
    Earth
    MS-Off Ver
    2016
    Posts
    692

    Re: apply macro to several tabs (variable)

    Like this?
    Please Login or Register  to view this content.
    MatrixMan.
    --------------------------------------
    If this - or any - reply helps you, remember to say thanks by clicking on *Add Reputation.
    If your issue is now resolved, remember to mark as solved - click Thread Tools at top left of thread.

  3. #3
    Forum Guru shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,655

    Re: apply macro to several tabs (variable)

    find all the tabs with specific text in their names
    Please Login or Register  to view this content.
    Entia non sunt multiplicanda sine necessitate

  4. #4
    Registered User
    Join Date
    12-17-2013
    Location
    texas
    MS-Off Ver
    Excel 2010
    Posts
    3

    Re: apply macro to several tabs (variable)

    Oh how glorious. I have no clue what I was doing wrong, that looks very similar to every iteration I was trying. In any event, thank you both!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. how to set a variable x to apply to the same formula across a spreadsheet
    By merisian in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 11-26-2018, 02:23 PM
  2. Apply a hide/unhide macro to all selected tabs
    By eric_be in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-22-2014, 08:50 AM
  3. [SOLVED] Macro to create new tabs based off of a type and apply conditional formatting
    By quintans1 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 10-03-2014, 10:56 AM
  4. [SOLVED] Apply Macro First UnprotectSheet After Apply Macro ProtectAgain Solved by : Sixthsense
    By HaroonSid in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 04-02-2014, 05:32 AM
  5. Macro Help - Trying to apply macro to multiple tabs
    By cvar1980 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-30-2010, 02:05 PM
  6. Apply Vlookup on multible tabs
    By kapil in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 08-05-2010, 10:29 AM
  7. Apply macro between tabs
    By mrsogmax76 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 10-03-2009, 10:53 AM

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