View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
cj
 
Posts: n/a
Default extracting numbers

thanks guys for the answer!

all 3 differrent formulas worked! i also need cell a2 to extract value of 8
if a1 is just "cash", value of 7 if a1 is "7cash",value of 6 if a1 is
"6cash", and so on and same for a3 to extract 8 if a1 is just "stock", etc.
and what if the order is reveresed from 3cash 4stock to 4stock 3cash?

plz help

"Biff" wrote:

Hi!

Enter this formula in A2:

=IF(ISERROR(LEFT(A1)*1),"",LEFT(A1)*1)

Enter this formula in A3:

=IF(ISERROR(MID(A1,FIND(" ",A1)+1,1)*1),"",MID(A1,FIND(" ",A1)+1,1)*1)

Biff

"cj" wrote in message
...
i need a formula to extract numbers.

if cell a1 is "3cash 5stock", i want to extract the number "3" to cell a2
and extract the number "5" to cell a3. the number in cash stock can vary
between 1 to 8 and vice versa.

can some help