Text Conditional formatting if cell not equal to another

Paul Naylor

Board Regular
Joined
Sep 2, 2016
Messages
99
Office Version
  1. 365
  2. 2003 or older
Platform
  1. Windows
  2. Mobile
  3. Web
Hoping someone can help?

Need to identify some variances in columns of text data . Although multiple columns I don't want to use multiple helper columns and thought easiest & most visually striking way is to use conditional formatting to highlight using a colour any differences in the 2nd column of data.

1st column C3-C47 contains manager call observation results to various questions ( text) and 2nd column G3-G47 contains quality team call observations results to the same set of questions.

All I would like is for any of the answers in the 2nd set of data are not equal to 1st set is for the relevant answer in the 2nd set to be highlighted in a colour.

I've tried to do this with conditional formatting , but all methods I've looked at seem to need an extra column , but with potentially 40 different comparisons spreadsheet will be unusable.

Anyone any ideas of how to do?

E.g. 2 columns of data on call observations answers to a number of questions. One set say in column C is managers observations and 2nd set say in column G is quality teams observations. Need to be able to identify by any differences between the managers observations and
 

Excel Facts

Will the fill handle fill 1, 2, 3?
Yes! Type 1 in a cell. Hold down Ctrl while you drag the fill handle.
would a countif() work

= countif($C$3:$C$47,G3)=0

But i feel maybe a lot more complicated then this , but i'm not really following so not sure why
dont understand this comment
but with potentially 40 different comparisons spreadsheet will be unusable.

A SMALL sample spreadsheet, around 10-20 rows, would help a lot here, with all sensitive data removed, and expected results mocked up and manually entered, with a few notes of explanation.

MrExcel has a tool called “XL2BB” that lets you post samples of your data and will allow us to copy/paste your sample data into our Excel spreadsheets, saving a lot of time.

You can also test to see if it works ok, in the "Test Here" forum.

OR if you cannot get XL2BB to work, or have restrictions on your PC

then put the sample spreadsheet onto a share

I only tend to goto OneDrive, Dropbox or google docs , as I'm never certain of other random share sites and possible virus.
Please make sure you have a representative data sample and also that the data has been desensitised, remember this site is open to anyone with internet access to see - so any sensitive / personal data should be removed

Make sure you set any share or google to share to everyone
 
Upvote 0
Hi eta,

Thanks for your reply. Just to clarify I'm comparing C3 to G3, C4 to G4, C5 to G5...etc , so if say G3 <> C3 I want G3 cell to be coloured Red , but C3 to remain un-coloured.
 
Upvote 0
ok,
then
try

=$C3<>$G3
as a rule

for 2007, 2010 , 2013 , 2016 , 2019 or 365 Subscription excel version
Conditional Formatting

Highlight applicable range >>
G3:G47 - Change, reduce or extend the rows to meet your data range of rows

Home Tab >> Styles >> Conditional Formatting
New Rule >> Use a formula to determine which cells to format
Edit the Rule Description: Format values where this formula is true:
=$C3<>$G3

Format [Number, Font, Border, Fill]
choose the format you would like to apply when the condition is true
OK >> OK

Book1
ABCDEFGH
1
2
3bd
4cc
514
622
71
833
9
Sheet1
Cells with Conditional Formatting
CellConditionCell FormatStop If True
G3:G8Expression=$C3<>$G3textYES
 
Upvote 0
Solution
Hi Etaf, thanks , seen online solution where highlight both columns and use same technique which highlights both columns , but didn't think that by using same process and selecting only the column I want to highlight would work.

Many ...many ..many thanks ..
Knew someone on the forum would know the best approach
 
Upvote 0
glad its worked for you
you are welcome
 
Upvote 0
Hi Etaf, Thanks for your solution, but i didnt factor in the fact that I need an additional check to be done . checks to non adjacent columns (CH & CK, CI & CL & CJ & CM , but only if value in the corresponding cell in row 33 = 1 i.e. CH33,CI33,CJ33( values can be 0 or 1 only) and the adjacent value in the corresponding cell <> do I want both cells to highlight in "Red" , formulas ( see below) using appear to work for this example,

Apply to Range:
CH5:CH32,CK5:CK32

Rule Type:
Formula

Format All Values Where Formula is True:
=IF(AND($SCH33,1),$CH5<>$CK5)

But not other instances where check digit in row 33 =0

Apply to Range:
K5:K32,N5:N32

Rule Type:
Formula

Format All Values Where Formula is True:
=IF(AND($K33,1),$K5<>$N5)
 

Attachments

  • Excel conditional formatting based on values 2.jpg
    Excel conditional formatting based on values 2.jpg
    42.3 KB · Views: 18
  • Excel conditional formating based on values in 2 columns 1.jpg
    Excel conditional formating based on values in 2 columns 1.jpg
    50.4 KB · Views: 13
Upvote 0
sorry, not sure i follow, 1 of the images will not open and to be honest, not really a good way to show the data - as i have to type it all in...... and cannot see any columns or row references - so have no idea how to correlate the wording to the images
BUT as i say , not keen on images

would you use 2XLBB or put on a share like onedrive/dropbox or google sheets

as i say , i'm not really following the explanation of what is needed now
 
Upvote 0
in your example I dont see these columns
checks to non adjacent columns (CH & CK, CI & CL & CJ & CM , but only if value in the corresponding cell in row 33 = 1 i.e. CH33,CI33,CJ33( values can be 0 or 1 only)

you have this formula
=IF(AND($B33,1),$B5<>$E5)

To test for row 33 only , if it =1
then you need
B$33=1
that then stops the row changing

and then add to the and

=AND( B$33=1, $B5<>$E5 )
BUT $B5<>$E5
means it will not change columns

so not really following again
column K and N have a zero in row 33

so why are they shown highlighted

also not sure which cells we are comparing now

B with E
C with F

can you manually colour the cells you want to highlight - and explain why - so perhaps i can see what you are now after

this is just applying the formula

=AND( B$33=1, B5<>E5 )
and so as conditional formatting moves across the columns - its checking
B with E
C with F
D with G
etc
which s wrong

Book7.xlsx
ABCDEFGHIJKLMN
2
3
4
5YesYesYesYesYesYesYesYesYesYesYes--
6NoYesYesNoYesYesYesYesYesYesYes--
7NoYesYesYesYesYesYesYesNoYesYes--
8YesYesYesYesYesYesYesYesYesYesYes--
9YesYesYesYesYesYesYesNoYesYesYes--
10YesYesYesYesYesYesNoYesYesYesYes--
11YesYesYesYesYesYesNoNoYesNoYes--
12YesYesYesYesYesYesMinor FeedbackYesYesMinor FeedbackYes--
13YesYesN/AN/AN/AN/AN/AN/AN/AN/AN/A--
14YesYesYesYesYesYesNoYesNoNoYes--
15YesYesN/AYesYesN/AYesYesYesYesYes--
16YesYesN/AYesYesN/AN/AYesYesN/AYes--
17YesYesYesYesYesYesYesYesYesYesYes--
18YesYesN/AYesYesN/AYesYesYesYesYes--
19YesYesN/AYesYesN/ANoNoNoN/ANo--
20N/ANoN/AN/ANoN/AN/ANoNoNoNo--
21YesYesYesYesYesYesNoYesNoNoYes--
22YesYesN/AN/AN/AN/AN/AN/AN/AN/AN/A--
23YesYesYesYesYesYesYesYesYesYesYes--
24YesYesYesYesYesYesYesYesMinor FeedbackYesYes--
25YesYesYesYesYesYesYesYesMinor FeedbackYesYes--
26N/AYesN/AN/AYesN/AN/AYesN/AN/AN/A--
27YesYesYesYesYesYesYesYesYesYesYes--
28N/AN/AN/AN/AN/AN/AN/AN/AN/AN/AN/A--
29YesYesYesYesYesN/AN/AYesYesYesYes--
30GoodGoodGoodGoodGoodGoodDevelopmentGoodPoorDevelopmentGood--
31209010090901000450065--
32Not meeting expectationSuccessful PerformanceSuccessful PerformanceSuccessful PerformanceSuccessful PerformanceSuccessful PerformanceNot meeting expectationNot meeting expectationNot meeting expectationNot meeting expectationInconsistent / Developing performance--
33111111110110
Sheet1 (2)
Cells with Conditional Formatting
CellConditionCell FormatStop If True
B5:N32Expression=AND(B$33=1, B5<>E5 )textYES


dropbox link only stays a few days , before i delete
 
Upvote 0

Forum statistics

Threads
1,223,234
Messages
6,170,891
Members
452,366
Latest member
TePunaBloke

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