Formula to change a cell color..

salsa79

New Member
Joined
Sep 25, 2011
Messages
6
Hello you all,

I wonder if any of you guys can help me with the following.

I have an excel file with columns A and B with text.

Column B has the same text as A, but can have corrections. Instead of using the tracking feature (as in Word), I would need a formula that highlights the cell whenever text on cell B is different from the one in cell A.

Can someone help please?

Much appreciated,
Claudia
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
Welcome to the MrExcel board!

To highlight the 'different' column B values, you would use Excel's Conditional Formatting feature.
On column B, you would use a Conditional Formatting formula like
=NOT(EXACT(A1,B1))
If you need more detailed help with that, tell us what version of Excel you are using.

Alternatively, in cell C1 you could put this formula and copy down:
=IF(EXACT(A1,B1),"","x")
That would put an "x" in column C of any row where the values are not identical.
 
Upvote 0
Welcome to the MrExcel board!

To highlight the 'different' column B values, you would use Excel's Conditional Formatting feature.
On column B, you would use a Conditional Formatting formula like
=NOT(EXACT(A1,B1))
If you need more detailed help with that, tell us what version of Excel you are using.

Alternatively, in cell C1 you could put this formula and copy down:
=IF(EXACT(A1,B1),"","x")
That would put an "x" in column C of any row where the values are not identical.

Hi Peter,

Many thanks for your warm welcoming and for helping me. I'm using excel 2003. How do I use the formula to change the cell color without using Format - Conditional formating menu? Or is it better to use this command?
Thanks again
 
Upvote 0
How do I use the formula to change the cell color without using Format - Conditional formating menu? Or is it better to use this command?
Thanks again
You cannot use a formula to change the colour of a cell without using Conditional Formatting.

Try this. Suppose you data is in A2:B10.

1. Select B2:B10
2. Format|Conditional Formatting...|Condituion 1|Formula Is| =NOT(EXACT(A2,B2))|Format...|Patterns tab|select a colour|OK|OK

Is there some special reason for wanting to avoid Conditional Formatting?
 
Upvote 0
You cannot use a formula to change the colour of a cell without using Conditional Formatting.

Try this. Suppose you data is in A2:B10.

1. Select B2:B10
2. Format|Conditional Formatting...|Condituion 1|Formula Is| =NOT(EXACT(A2,B2))|Format...|Patterns tab|select a colour|OK|OK

Is there some special reason for wanting to avoid Conditional Formatting?

Not at all Peter, it was just a question, I'm not the expert here ;-) Let me try this, many, many thanks. Be right back...
 
Upvote 0
Peter,

Actually the formula is with ";" and not "," :

=NOT(EXACT(A2;B2))


I've manged to find this out ;-)

I'm really glad, your help has saved me lots a time!! :-)
 
Upvote 0
Actually the formula is with ";" and not "," :

=NOT(EXACT(A2;B2))
That indicates that you are using a version of Excel that is not a standard English version, as mine is.

Of course, there is nothing wrong with that but you will need to be aware of possible differeneces in language versions when asking questions in this forum since the vast majority of users here do use a standard English version.

Anyway, I'm glad you've got a solution that is working for you. :)
 
Upvote 0
Hi Peter,

I didn't know about that ;-)
But by standard you mean UK or US? Actually my Excel is in English from United States, but maybe the country settings (Portugal) also have something to do with it, don't know.

Thanks again,
 
Upvote 0

Forum statistics

Threads
1,224,583
Messages
6,179,683
Members
452,938
Latest member
babeneker

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