View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
rgarner rgarner is offline
external usenet poster
 
Posts: 1
Default how do I use only 2 characters in a field in a formula

A1 B1
MH*97*14*80 96

I want to us the first 2 characters in A1 in a formula to place a value in B1

If the 1st 2 characters in A1="MH" or "AP" then B1=96 else B1=90

How do I write that formula? (How do I use any of the characters, for
instance, if I want to use the 4th and 5th characters, 97)?

Thanks.