+ Reply to Thread
Results 1 to 10 of 10

Changing tab colors

  1. #1
    Forum Contributor
    Join Date
    12-03-2009
    Location
    California
    MS-Off Ver
    Excel 2010
    Posts
    184

    Changing tab colors

    Trying to change tab color with a worksheet change vba. It works if I eliminate the first if line and last end if. But I need the first if command or it causes other issues.


    HTML Code: 

    Thanks,

    Madison

  2. #2
    Forum Contributor
    Join Date
    12-03-2009
    Location
    California
    MS-Off Ver
    Excel 2010
    Posts
    184

    Re: Changing tab colors

    Ok, I can see its getting kick out from that first line but how do I change that?

  3. #3
    Forum Guru Winon's Avatar
    Join Date
    02-20-2007
    Location
    East Rand, R.S.A.
    MS-Off Ver
    2010
    Posts
    6,113

    Re: Changing tab colors

    Hello enhydra,

    It is hard to tell, without a sample Workbook. Taking a wild guess, please try;

    Please Login or Register  to view this content.
    Regards.
    Last edited by Winon; 10-09-2017 at 01:04 PM. Reason: Corrected Code
    Please consider:

    Be polite. Thank those who have helped you. Then Click on the star icon in the lower left part of the contributor's post and add Reputation. Cleaning up when you're done. If you are satisfied with the help you have received, then Please do Mark your thread [SOLVED] .

  4. #4
    Forum Expert leelnich's Avatar
    Join Date
    03-20-2017
    Location
    Delaware, USA
    MS-Off Ver
    Office 2016
    Posts
    2,807

    Re: Changing tab colors

    Hi all
    Please Login or Register  to view this content.
    Last edited by leelnich; 10-09-2017 at 12:35 PM.
    Clicking the Add Reputation star below helpful posts is a great way to show your appreciation.
    Please mark your threads as SOLVED upon conclusion (Thread Tools above Post # 1). - Lee

  5. #5
    Forum Contributor
    Join Date
    12-03-2009
    Location
    California
    MS-Off Ver
    Excel 2010
    Posts
    184

    Re: Changing tab colors

    I now get "End if without block if".

  6. #6
    Forum Guru Winon's Avatar
    Join Date
    02-20-2007
    Location
    East Rand, R.S.A.
    MS-Off Ver
    2010
    Posts
    6,113

    Re: Changing tab colors

    Oops, Sorry!

    Just delete the End If before End Sub.

  7. #7
    Forum Contributor
    Join Date
    12-03-2009
    Location
    California
    MS-Off Ver
    Excel 2010
    Posts
    184

    Re: Changing tab colors

    OK, working now. Thanks

  8. #8
    Forum Expert leelnich's Avatar
    Join Date
    03-20-2017
    Location
    Delaware, USA
    MS-Off Ver
    Office 2016
    Posts
    2,807

    Re: Changing tab colors

    And also sorry, I missed the single line/exit sub thing (not my favorite construction). My post #4 code is now updated.

  9. #9
    Forum Guru Winon's Avatar
    Join Date
    02-20-2007
    Location
    East Rand, R.S.A.
    MS-Off Ver
    2010
    Posts
    6,113

    Re: Changing tab colors

    Hi enhydra,

    Thank you for the feedback.

    You don't however state which contribution solved your issue, but you are welcome. Glad your issue has been solved.

    Regards.

  10. #10
    Forum Contributor
    Join Date
    12-03-2009
    Location
    California
    MS-Off Ver
    Excel 2010
    Posts
    184

    Re: Changing tab colors

    I used yours Winon. Thanks

+ 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. Changing cells and column chart colors based on cell colors
    By HDeuce in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-03-2016, 11:43 AM
  2. Replies: 3
    Last Post: 10-21-2015, 03:51 PM
  3. Changing colors
    By jackandjill in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-29-2010, 09:25 PM
  4. changing colors
    By sydmil in forum Excel General
    Replies: 1
    Last Post: 11-06-2008, 07:40 PM
  5. Changing colors?
    By Lee in forum Excel General
    Replies: 1
    Last Post: 05-22-2006, 10:15 PM
  6. [SOLVED] Changing the colors
    By Prado in forum Excel General
    Replies: 2
    Last Post: 03-03-2005, 03:06 PM
  7. [SOLVED] Changing colors
    By davetteb in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 02-18-2005, 10:06 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