excelspecial-charactersconditional-formattingalphabetic

Conditional Format Cells with Special Characters including Accented Letters, Numbers, and Punctuation


I'm using Excel Version 2411, and I'm working on a file where I need to apply conditional formatting that will highlight a cell if the cell contains any characters that aren't abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ or space. I need it to flag anything including numbers, punctuation, special characters and accented letters or any combination thereof.

Example Data that should flag:
Paul Niño
SAMANTHA JANE-SMITH
homer dukedom_123
Jane Doe2*
Jane,Smith
George Earl (Billing)

What I've tried previously: I created a table with 83 lines of data to include all the common punctuation, numbers, and accented letters / specialty letters and special characters. I named the Table and also created a named range that references the Table.

I learned through google searching apparently you can't use the =Special_Characters_T[Special_Characters] Table reference coding in Conditional formatting.

So I tried the named range =Special_Characters in conjunction with the Cell Value Contains conditional formatting rule. It doesn't throw an error, but it also doesn't highlight everything.

I've also tried the following formulas that I found online:

=ISERROR(SUMPRODUCT(SEARCH(MID(A1,ROW(INDIRECT("1:"&LEN(E4))),1),"abcdefghijklmnopqrstuvwxyz")))

=SUMPRODUCT(--(LEN(SUBSTITUTE(E4, MID("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ", ROW(INDIRECT("1:" & LEN("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"))), 1), "")) < LEN(E4)))

However they aren't flagging the accented characters and characters like , or .

I've also tried using various CountIf formulas, without success.

What I'm finding is that often the solutions I'm trying either don't highlight everything or don't highlight when there is more than one match (Example: Jane Smith-Paul2, - and 2 would both be true)


Solution

  • I think you were on the right track, a little tinkering led me to the following formula which seems to work (at least on your examples and their counter-examples):

    =SUMPRODUCT(--ISNUMBER(
      FIND(
        MID(A1,ROW(INDIRECT("1:"&LEN(A1))),1),
        "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ ")))<>LEN(A1)
    

    enter image description here