+ Reply to Thread
Results 1 to 2 of 2

Automatically change sheet tab color based on sheet name

  1. #1
    Registered User
    Join Date
    07-31-2023
    Location
    Washington, DC
    MS-Off Ver
    Version 2306
    Posts
    2

    Automatically change sheet tab color based on sheet name

    Hi there!

    I've created a web automation that scrapes flight data from the web and stores it into an Excel doc. It automatically creates a new sheet for each flight search I have it perform. It renames each sheet based on the departure/arrival location and the date of the flights I'm searching for (Example sheet names: "DC-NY | 9-14-23" or "NY-DC | 9-15-23").

    I only search for flights between these two destinations. I'm trying to create a Macro that automatically changes the color of each new tab created for flights from DC-NY to Red and all flights from NY-DC to Blue. Basically I need the Macro to change the color of the tab based only on the first part of the sheet name and ignore the date also included in the name because that date changes with each new sheet that gets created.

    Hope I was able to explain that clearly enough. Any help would be greatly appreciated!

    Thanks!

  2. #2
    Valued Forum Contributor ranman256's Avatar
    Join Date
    07-29-2012
    Location
    Kentucky
    MS-Off Ver
    Excel 2003
    Posts
    1,177

    Re: Automatically change sheet tab color based on sheet name

    something like:

    Please Login or Register  to view this content.

+ 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. change shape color based on a cell value on another sheet
    By aleenkhan in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-14-2017, 11:14 AM
  2. Change color of shapes based on a value on another sheet
    By dreddster in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-24-2016, 05:41 PM
  3. Shape Color Change Based on Value in different sheet
    By kevinspocket in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-17-2014, 05:50 PM
  4. [SOLVED] How to change sheet tab color based on its condition
    By saesaria in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-20-2013, 12:32 PM
  5. Change sheet tab color based on variable
    By excelstacy in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-29-2011, 11:22 AM
  6. How can I change sheet tab color based on cell value in sheet?
    By SCAScot in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-23-2005, 05:50 PM
  7. How do I change the Cell color automatically in an Excel sheet wh.
    By stump in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-06-2005, 11:06 AM

Tags for this Thread

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