IF Function, maybe

  • Thread starter Thread starter Joe
  • Start date Start date
J

Joe

In one column there is an indication of either F (for
female) or M (for male). I want to create a formula in
the next column that will say: Ms. if F, or Mr. if M.

Please help
 
Hi, I tried your formula but I get the value of Mr. for
all the column, i.e. it does not recognize: Ms.
 
Hi Joe!

To cover the blank cells pending entry use:

=IF(ISBLANK(A1),"",IF(A1="F","Ms.","Mr."))
 
Hi Norman,

The column does not have any blank values. The column
cells contain either F or M. In any case, I used the
function you gave me and it still does not recognize the
F values, i.e. the end result is "Mr." where it is F or M.
 
Hi Joe!

I suspect that your F and M data has spaces in it and " F" is not
treated as "F" and returns Mr.

Try:

=IF(ISBLANK(A1),"",IF(TRIM(A1)="F","Ms.","Mr."))
 
Back
Top