wikiHow is a “wiki,” similar to Wikipedia, which means that many of our articles are co-written by multiple authors. To create this article, 14 people, some anonymous, worked to edit and improve it over time.
This article has been viewed 152,098 times.
Learn more...
Learning the IF function is the first step to understanding using advanced functions in spreadsheets such as Microsoft Excel, spreadsheets.google.com, OpenOffice.org Calc, KSpread, iNumbers or Gnumeric. An IF statement is a useful operation to use in Excel. It tests to determine if a certain condition in a spreadsheet is true or false by comparing a value to that of a cell to a user-set condition, and replaces it with input that the user sets as well. It sounds complicated, but formulating an IF statement is not at all hard.
Steps
Community Q&A
-
QuestionI'm trying to write a formula for if a cell is below 883 that a zero appears or if it's above 883 the difference appears. What can I do?Community AnswerIn EXCEL 2016, click on the Help or "Tell Me" space in the toolbar and then type in "formula" in the search area. You will get several choices, one of them is "IF Formula." Click on that and you will get a straightforward explanation of how to do what you want to do.
-
QuestionHow do I use an IF function if there are three possible values?Community AnswerWhen you have more than 2 potential values for entry, use a nested IF statement. In your case, since there are 3 potential values, you will need to create a logical test for criteria for all but 1 of these potential value. The untested becomes the "value if false" entry. Think back to the if statement function: =if(logical test, value if true, value if false). In a nested if statement, the logical test and the value if true is repeated within the if statement function until you are left with only 1 remaining value (value if false) for entry. For example: =if(logical test 1, value if true, if(logical test 2, value if true, if(logic test 3,value if true, value if false))).
-
QuestionHow do I use the IF function to consider a word?Community AnswerIt is very similar; for example: =if(a2="Female", "True", "False"). Just make sure you use quotation marks.