Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
if statement does not work with = sign
I am trying to use this function:
If(b44=b46, "Balance","Not balance"). b44 and b46 are exactly the same dollar value. Both cells are formatted for currency. The cell that the text is written is formatted as general. Both b44 and b46 are calculated cells that add a column of numbers. Have tried using sum statement instead of b44,46 etc. In the watch window both values are the same, but the b44=b46 statement is false. Thanks for your help. Bill |
#2
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
if statement does not work with = sign
Bill,
Excel, like nearly all computer programs, use what is called "double-precision floating point numbers", which are limited to 15 digits of precision. Cells that appear equal may differ by some very small amount, the error introduced by rounding. See www.cpearson.com/excel/rounding.htm for more details. You could write your formula like =IF(ABS(B44-B46)<0.00000001,"Balance","Not Balance") -- Cordially, Chip Pearson Microsoft MVP - Excel Pearson Software Consulting, LLC www.cpearson.com "BBinSimi" wrote in message ... I am trying to use this function: If(b44=b46, "Balance","Not balance"). b44 and b46 are exactly the same dollar value. Both cells are formatted for currency. The cell that the text is written is formatted as general. Both b44 and b46 are calculated cells that add a column of numbers. Have tried using sum statement instead of b44,46 etc. In the watch window both values are the same, but the b44=b46 statement is false. Thanks for your help. Bill |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Linking with equals sign doesn't always work | Excel Worksheet Functions | |||
# sign in a cell | Excel Discussion (Misc queries) | |||
Work book formulas | Excel Discussion (Misc queries) | |||
How to copy the work sheets from different workbooks into one? | Excel Discussion (Misc queries) | |||
Change Path names in copied work book | Excel Worksheet Functions |