Change row colour when value changes

RubberChicken

Board Regular
Joined
Jun 20, 2013
Messages
50
Hi guys

I have a spreadsheet with thousands of rows.
I want to break the row colour up by the reference in column A.
2 alternating colours is fine. It is only to make the data easier to read and see the groups.
So the reference is repeated in column A over a variable amount of rows. Then a new reference for the next few rows and so on.
I'd like the row colour to change when the reference changes.
I think I have seen it done with a =MOD formula and conditional formatting, but I can't find that now.
Any ideas?

Cheers
 
Sheet2

ABC
1IDNameXXX
22163Heather45

<colgroup><col style="width: 30px; font-weight: bold;"><col style="width: 85.6px;"><col style="width: 85.6px;"><col style="width: 85.6px;"></colgroup><tbody>
</tbody>

Spreadsheet Formulas
CellFormula
B2{=IFERROR(INDEX(Sheet1!B$2:B$20,MATCH($A2,Sheet1!$A$2:$A$20,0)),"")}
C2{=IFERROR(INDEX(Sheet1!C$2:C$20,MATCH($A2,Sheet1!$A$2:$A$20,0)),"")}

<tbody>
</tbody>
Formula Array:
Produce enclosing
{ } by entering
formula with CTRL+SHIFT+ENTER!

<tbody>
</tbody>


Excel tables to the web >> Excel Jeanie HTML 4
 
Upvote 0

Excel Facts

Can you sort left to right?
To sort left-to-right, use the Sort dialog box. Click Options. Choose "Sort left to right"
This is getting a bit off topic - I'm using a newer version so maybe that is why. Note that I can't find an English version of the version I'm using though.

For that reason I usually use the MrExcel HTML maker, and only resort to Excel Jeanie when I want to show conditional formatting.
 
Upvote 0
Yes! Thank you FormR
That's given me exactly what I need.
I don't know what "NOT(N(B1)"is doing but it works.

Thanks BillyRay, Thanks FormR


 
Last edited:
Upvote 0
Glad to help and thank you too for being part of the forum. I appreciate this resource very much.

Also thank you FormR and sorry to ask something off topic.
 
Upvote 0
Upvote 0

Forum statistics

Threads
1,215,461
Messages
6,124,953
Members
449,198
Latest member
MhammadishaqKhan

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