Tag Archives: Color

No Thumbnail

VBA Excel, Colors

This article explain how you can work with colors in VBA for Excel. When working with Excel there are many cases when you will need to specify a color: When selecting a fill color When changing the font color When changing the border color … To

No Thumbnail

Excel VBA Border Colors

One of the things you probably want to modify when working with borders in VBA for Excel is the border color. Previously I’ve explained about colors in the article VBA Excel Colors. Therefore I’m assuming readers are familiar with the basic concept of working with

No Thumbnail

Excel VBA Remove Column Fill Color

The following line of code removes the fill color of the first column: Columns(1).Interior.Color = xlNone  Before: After: See also: Excel VBA, Cell Fill Color Excel VBA, Formatting Cells and Ranges using the Macro Recorder If you need assistance with your code, or you are looking

No Thumbnail

Excel, Can’t Remove Cell Fill Color

If you have an Excel workbook with cells that have a fill color that can’t be removed, there are 2 possible reasons for this. – Reason #1, Conditional Formatting: Conditional formatting might have been applied to the cell or range. Conditional formatting will create a

No Thumbnail

Excel VBA, Row Fill Color

The following line changes the fill color of the first row to blue: Rows(1).Interior.Color = vbBlue Same as the previous line but instead of using the blue color constant it uses the blue color code Rows(1).Interior.Color = 16711680 For more information about working with colors in

No Thumbnail

Excel VBA, Sheet (All Cells) Fill Color

The following line changes the fill color of all the cells in sheet 2 to blue: Sheet2.Cells.Interior.Color = vbBlue Same as the previous line but instead of using the blue color constant it uses the blue color code Sheet2.Cells.Interior.Color = 16711680 For more information about working with

No Thumbnail

Excel VBA, Cell Fill Color

In this article I will explain how you can set and get the fill color of cells using VBA. For more information about using colors in VBA for excel please see VBA Excel Colors. Jump To: Set Get – Set: The code below changes the fill

No Thumbnail

Excel VBA Remove Range Fill Color

The following line of code removes the fill color of the range A1:B2: Range(“A1:B2”).Interior.Color = xlNone The following line of code does the same: Range(Cells(1, 1), Cells(2, 2)).Interior.Color = xlNone Before: After: See also: Excel VBA, Cell Fill Color Excel VBA, Formatting Cells and Ranges using

No Thumbnail

Excel VBA, Color Dialog xlDialogEditColor

The xlDialogEditColor is a dialog used to get a color code from the user. Color codes are used to specify colors in VBA for Excel. For more information about working with colors please see Excel VBA Colors. Jump To: Syntax Examples Example 2, Set Fill Color You can