Results 1 to 3 of 3

Trying to change the tab colour

Threaded View

sweths27 Trying to change the tab... 09-18-2013, 09:51 PM
venkat1926 Re: Trying to change the tab... 09-19-2013, 03:45 AM
Andy Pope Re: Trying to change the tab... 09-19-2013, 04:17 AM
  1. #1
    Registered User
    Join Date
    09-18-2013
    Location
    India
    MS-Off Ver
    Excel 2007
    Posts
    1

    Trying to change the tab colour

    Hi,

    We generally use excel file where there would be various tabs, however we have two sheet tabs named PPT START and PPT END.
    We will do the necessary work in between these tabs only. We will ignore the remaining tabs prior and post to the above mentioned tabs.
    I want to change the colour of the sheet tabs in a random choice of colors irrespective of the sheet tab names.
    I got the logic that is post the sheet tab of PPT START the loop starts and changes the colour of the sheet tab and the loop ends when it reaches to the PPT END.. but i am not able to implement it.. struck with the loop iteration.. pls help me guys..

    Sub Test()
    '
    ' Test Macro
    '
    
    '
    Sheets("PPT START").Select
        With ActiveWorkbook.Sheets("Sheet2").Tab
            .Color = 255
        End With
        Sheets("Sheet3").Select
        With ActiveWorkbook.Sheets("Sheet3").Tab
            .Color = 65535
        End With
    End Sub
    This is without the loop.. when i try to declare variable it throws an error...

    Thanks in Advance!!!!
    Last edited by arlu1201; 09-19-2013 at 02:16 AM. Reason: Use code tags in future.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Change colour of cells based on another cell's colour (Not value)
    By LTrain89 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 06-25-2013, 08:44 PM
  2. Replies: 2
    Last Post: 06-07-2011, 07:00 AM
  3. Colour change column chart based on cell colour
    By Alice21 in forum Excel General
    Replies: 11
    Last Post: 04-05-2011, 10:10 AM
  4. How to make row change colour based on text colour in row?
    By Joanna13 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-02-2010, 04:39 PM
  5. change a cell background colour to my own RGB colour requirements
    By Stephen Doughty in forum Excel General
    Replies: 4
    Last Post: 06-16-2006, 08:15 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