Calculate cell numbers only not letters

LuckyD

New Member
Joined
Nov 14, 2005
Messages
3
In cell K17 I have 2

In cell L16 I have Volume x5

In cell L17 I have =K17*L16

In cell L17 I get #VALUE!
I want L17 to read 10.
I have tried =K17*INT(L16) which didn't work.
I just want it to calculate only the numbers in cell L16.

Thanks
 

Some videos you may like

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.

Smitty

Legend
Joined
May 15, 2003
Messages
29,536
Welcome to the Board!

Not advisable, but

=K17*RIGHT(L16,LEN(L16)-FIND("x",L16))

should work (privoded the number is always prefaced by an "x").

If you can swing it, keep the Volumn Amount in a separate cell. It greatly simplifies things.

Hope that helps,

Smitty
 

LuckyD

New Member
Joined
Nov 14, 2005
Messages
3
Wow more complicated then I figured. In my basic programming class like 5 years ago it was easy to seperate integers from strings.
 

Yogi Anand

MrExcel MVP
Joined
Mar 12, 2002
Messages
11,454
Hi Lucky:

For your entries in cells K17 and L16 as you have posted ...

in cell L17, you can use the formula ...

=K17*RIGHT(L16)
or
=K17*SUBSTITUTE(L16,"x","")

If you need a more general solution you have to provide better specification for possible entries in cell L16.
 

Nimrod

MrExcel MVP
Joined
Apr 29, 2002
Messages
6,259
LuckyD
Another method would be to Custom format cell L16 with the format x#
When you put the number 5 in the cell the view you be x5. Doing this way will allow you to use your original formula.
 

LuckyD

New Member
Joined
Nov 14, 2005
Messages
3
Thanks for all your help

This will greatly improve my ability to quick change my volumes and concentrations.
 

Watch MrExcel Video

Forum statistics

Threads
1,118,731
Messages
5,573,880
Members
412,555
Latest member
mark84
Top