Change Fill Color on Row When Name Changes

stanleytheyak

Board Regular
Joined
Oct 10, 2008
Messages
124
I have a sheet that is similar to the following:

ABC
1NameItemDescription
2Tom Smith1Item 1
3John Adams2Item 2
4John Adams3Item 3
5Ronald Regan4Item 4
6Ronald Regan5Item 5
7Ronald Regan6Item 6
8John Kennedy7Item 7
9John Kennedy8Item 8
10John Kennedy9Item 9
11John Kennedy10Item 10

<colgroup><col span="2"><col><col></colgroup><tbody>
</tbody>

What I would like to do is to have each name in column A determine fill color for the row. So, Row 2 (Tom Smith) would be green. Rows 3-4 (John Adams) would be light green. Rows 5-7 (Ronald Regan) would be blue. And so on.

I need to automate this, as the list changes frequently. Names are added/removed, items are added, etc.

Any help in doing this would be greatly appreciated!
 

Excel Facts

Save Often
If you start asking yourself if now is a good time to save your Excel workbook, the answer is Yes
It seems that the color is different for each name. If this is correct, you would need a list of names, perhaps in a separate sheet, along with the corresponding colors for each name. If names are added, you would need to update the names and colors on the separate sheet.
 
Upvote 0

Forum statistics

Threads
1,214,959
Messages
6,122,476
Members
449,087
Latest member
RExcelSearch

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top