Forum

Notifications
Clear all

Multiple String Search in Cell

5 Posts
3 Users
0 Reactions
179 Views
 TimC
(@timc)
Posts: 32
Trusted Member
Topic starter
 

I have a formula =SEARCH($AY$3,AY6,1)>0 in conditional formatting, which says if the string in AY6, is found in a range, turn any of the cells that contain

that string to red. Is it possible to change the formula, to look for more than one string.

 
Posted : 20/05/2017 11:19 am
(@sunnykow)
Posts: 1417
Noble Member
 

Hi Tim

Give this a try.

Sunny

 
Posted : 20/05/2017 9:03 pm
(@catalinb)
Posts: 1937
Member Admin
 

Hi Tim,

Use a table with multiple values to search, this formula for conditional formatting will do the job:

=SUM(IFERROR(SEARCH(StringsToSearch,A2),0))>0

Where StringsToSearch is a defined name, for 1 or more cells (unlimited number of cells) containing your text to search.

By default, in named ranges or in conditional formatting rules, these formulas are treated like array formulas, so they can be designed as array formulas, but they do not have to be entered with CSE like worksheet cell array formulas.

 
Posted : 21/05/2017 2:02 am
 TimC
(@timc)
Posts: 32
Trusted Member
Topic starter
 

Works a treat.

Many thanks, Catalin.

Presumably, Sunny was going to suggest something similar?

Kind regards,

Tim C

 
Posted : 31/05/2017 12:41 pm
 TimC
(@timc)
Posts: 32
Trusted Member
Topic starter
 

 . . . as he indeed did.

 
Posted : 31/05/2017 12:43 pm
Share: