Formatting Font and Background Colors in Excel Spreadsheet

We can write Excel VBA code to format the color of a MS Excel spreadsheet. Using  Excel VBA code, we can change the font color as well as the the background color of each cell effortlessly.

Alright, let’s create a program that can format random font and background colors using a randomize process. Colors can be assigned using a number of methods in Excel VBA, but it is easier to use the RGB function. The RGB function has three numbers corresponding to the red, green and blue components. The range of values of the three numbers is from 0 to 255. A mixture of the three primary colors will produce different colors.

More details here:

http://excelvbatutor.com/index.php/excel-vba-lesson-12/