0 votes
in VBA by Beginner (104 points)
I mean changing font color and font size for a range to make the spreadsheet more appealing in VBA rather than volatile conditional formating.

1 Answer

0 votes
by Skilled (306 points)

You can use such lines to control the font properties

Sub Change_Font_Size_Name_Color()
    With ActiveSheet.Range("A1:C10").Font
        .Size = 16
        .Name = "Arial"
        .Color = vbRed
    End With
End Sub


ago by Beginner (100 points)

You can use the "Colorindex" attribute. This article goes into detail on how to use it to set colors, including a list of 56 values to set specific colors:


Here's an infographic with the VBA ColorIndex colors and predefined VBA colors.


Welcome to wellsr Q&A
wellsr Q&A is the VBA and Python programming community that rewards you for learning how to code.

Earn free prizes for asking VBA and Python questions and for answering questions asked by others in our community.

What makes us different?
Our points system rewards you with a chance for free gifts as your contributions grow. The more points you earn, the better the prizes.

Getting Started

For more programming tips visit the VBA Tutorials Blog and the Python Tutorials Blog.

Top Users Mar 2019
  1. YasserKhalil

    306 Points

  2. ParserMonster

    204 Points

  3. Alberto Semat

    186 Points

  4. danmcg

    127 Points

  5. Abdan

    124 Points

Prizes for March 2019
Terms and Conditions
1st place (1) 1-year MyExcelOnline Academy Membership
(2) My First Add-in Dev Pack & Course
(3) AutoMacro: VBA Code Generator (Developer)
(4) VBA Cheat Sheet Bundle
(5) $35 Amazon Gift Card
2nd place (1) My First Add-in Dev Pack & Course
(2) 101 Most Popular Excel Formulas E-Book
(3) VBA Cheat Sheet Bundle
(4) $25 Amazon Gift Card
3rd place (1) Mouse to Macro
(2) VBA Cheat Sheet Bundle
(3) $15 Amazon Gift Card