+ Reply to Thread
Results 1 to 2 of 2

Changing the font color using VBA

  1. #1
    Registered User
    Join Date
    03-27-2005
    Posts
    13

    Changing the font color using VBA

    I have VBA code that changes the background color of a cell but I would also like to change the color of the font.

    The code below changes the cell RED but I would also like the font WHITE.



    code:
    --------------------------------------------------------------------------------
    Case Cells(CurrRow, 8) < 80
    CurrRow = Thing.Row
    Range(Cells(CurrRow, 8), Cells(CurrRow, 8)).Select
    'Grab column 1 where found
    With Selection.Interior
    .ColorIndex = 3 '3=red
    .Pattern = xlSolid
    End With
    --------------------------------------------------------------------------------

  2. #2
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,525
    Hi

    Case Cells(CurrRow, 8) < 80
    CurrRow = Thing.Row
    Range(Cells(CurrRow, 8), Cells(CurrRow, 8)).Select
    'Grab column 1 where found
    With Selection.Interior
    .ColorIndex = 3 '3=red
    .Pattern = xlSolid
    .Font.ColorIndex=2
    End With

+ 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