How to make logical statements output numbers

July 6, 2009 at 13:31:57
Specs: Windows XP
I am trying to find a way to cause a logical
statement to cause another cell to output a
number such as "4" if true and "0" if false. That
is not where my problem lies,however. My
problem comes when I try to sum a column of
numbers generated from an if/then statement.
Excel seems to treat the numbers as
symbols/words and not numbers. Thus, a
summation of the cells outputs a zero
because technically, no numbers are there.
Any ideas. I would greatly appreciate it.

See More: How to make logical statements output numbers

Report •

July 6, 2009 at 13:36:11
PS: I have tried this on excel 2003 and 2007. I assume that if
this issue can be overcome, it should transcend the version of
excel as I am sure it is something really simple like a specific
equation or something.

Report •

July 6, 2009 at 14:13:24
The answer:

My if/then statement was set up as follows;


This caused excel to treat the 4 and 0 as words and not
numbers. Therefore, I could not sum them up. By removing the
parenthesis, excel would treat them as numbers and I could
add them. :D

The statement should read:


Alternatively, it should be noted that the 4 and 0 can also be
replaced with a cell such as C7.

Report •

July 6, 2009 at 18:23:05
Just as an FYI...

Excel really likes numbers, so if you are stuck with a "text number" Excel will usually allow you to perform an arithmetic operation on it and turn it into a number.

For example, both of these would have solved your problem also:


So would have a Copy/Paste Special...Add of 0 or a blank cell, Copy/Paste Special...Multiply of 1, etc.

Maybe these tips will help you in the future.

Report •

Related Solutions

Ask Question