Pimp My Excel

Pimp My Excel

Wow your boss or your friends with this beautiful Excel macro.

It takes a boring Excel worksheet and pimps it out. A lot of people use color senselessly when using data, so I wanted to automate that process.

Here are a couple examples so that you can see this macro in action. Here are statistics for the New York Red Bulls. They are so boring. You won’t be able to make any convincing arguments using these stats.

NY Red Bulls Stats... Lame Sauce
NY Red Bulls Stats… Lame Sauce

Wow! Look at the following pimped out chart. Everyone will believe your arguments now.

NY Red Bulls Stats Pimperish!
NY Red Bulls Stats Pimperish!

Ugg. This income statement for Google is so boring. You can’t use this data to successfully invest in the market.

Google Income Statement... Boring
Google Income Statement… Boring

Pimperish! Now you are ready to make some bucks.

Google Income Statement Pimped Out!
Google Income Statement Pimped Out!

How to Use

Download the .bas Excel macro file of Pimp My Excel

Make sure your Excel is able to run macros. You may have to change your Excel settings to do this.

Open the Visual Editor in Excel. Do this with Alt+F11.

Right click on the project area and select Import File. Select the PimpMyExcel.bas file.

Make sure you have the sheet open in Excel that you want to pimp out.

Run the macro called PimpMyExcel.

Programming Notes

This was a pretty straightforward macro to create. The big issue I ran into was the limitations that Excel imposes on the number of font types and cell formats. Excel has a maximum limit of 512 different fonts. In Excel 2000 and later the maximum number of cell formats is approximately 4,000 different combinations and in Excel 2007 and higher the maximum number of cell formats is 64,000. In order to prevent going over these numbers I hardcoded the font colors and cell background colors in the code.

I also chose to On Error Resume Next to handle the errors as Excel continued to throw errors in regards to the cell format issues. This seems to work for most large worksheets.