IF Function - Begins With

C

Cecil

How do I apply the "begins with" filter to an IF statement? I would
like to test a match on the first 3 characters of a string in a given
cell?
 
S

SteveG

Cecil,

=IF(LEFT(A1,3)="ABCD",A1,"")

This will look at the 3 leftmost characters and return a value if it is
true.

Regards,

Steve
 
S

SteveG

Cecil,


=IF(LEFT(A1,3)="ABC",A1,"")

Only indicate 3 characters in quotes. My last example had 4. Sorry!

Cheers,

Steve
 
Top