Excel: IF Function Returns 0 Instead of TRUE or FALSE

Last reviewed: November 2, 1994
Article ID: Q75821

SUMMARY

Page 125 of the "Microsoft Excel Function Reference" version 3.0 manual incorrectly states that "If logical_test is TRUE and value_if_true is omitted, TRUE is returned" and "If logical_test is FALSE and value_if_false is omitted, FALSE is returned."

If value_if_true is not included in the formula "=IF(logical_test,,value_if_false)", then 0 (zero) will be returned if logical_test is TRUE. If value_if_false is not included in the formula "=IF(logical_test,value_if_true,)", then a 0 will be returned if logical_test is FALSE. However, if value_if_false is left off in the formula "=IF(logical test,value_if_true)", then FALSE will be returned when logical_test is FALSE.

MORE INFORMATION

To get the IF function to return either TRUE or FALSE depending on the value of logical_test, value_if_true and value_if_false should have TRUE and FALSE entered for their respective arguments. For example, the following formula

   =IF(logical_test,TRUE,FALSE)

will return TRUE if logical_test is TRUE and FALSE if logical_test is FALSE.


KBCategory: kbother
KBSubcategory:

Additional reference words: noupd


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: November 2, 1994
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.