How do I find specific words and reference it

S

Shaz

I want Excel to say "Westmidlands" if Postcode in column J starts with "B or
CV or W" and "Scotland" if the postcode starts with "AB or G". How do I do
that?
 
L

Lars-Åke Aspelin

I want Excel to say "Westmidlands" if Postcode in column J starts with "B or
CV or W" and "Scotland" if the postcode starts with "AB or G". How do I do
that?

Try this formula:

=IF(OR(EXACT(LEFT(J1,1),"B"),EXACT(LEFT(J1,2),"CV"),
EXACT(LEFT(J1,1),"W")),"Westmidlands",IF(OR(EXACT(LEFT(J1,2),"AB"),
EXACT(LEFT(J1,1),"G")),"Scotland","not specified what to say"))

Hope this helps / Lars-Åke
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top