Excel if then function tutorial. If logic testvalue if truevalue if false. Like every function and formula in excel if is based on a specific syntax. So an if statement can have two results. If logicaltest valueiftrue valueiffalse.
Excel if function syntax and usage the if function is one of logical functions that evaluates a certain condition and returns the value you specify if the condition is true and another value if the condition is false. Multiple if statements in excel are known as nested if statements. The and function returns true if the first score is greater than or equal to 60 and the second score is greater than or equal to 90 else it returns false. Inputting if then in excel the syntax of the if then function includes the name of the function and the function arguments inside of parenthesis.
For example if sales total more than 5000 then return a yes for bonus otherwise return a no for bonus. Notice how the formula inputs appear. This tutorial demonstrates how to use excel if with an easy to follow example. Learn how to use the if function in microsoft excel.
The syntax for if is as follows. Of all the many functions in excel the if function is often the first function new users turn to. The if function is one of the most popular functions in excel and it allows you to make logical comparisons between a value and what you expect. The reader is given the syntax for the if function including an explanation of the terms.
The if function checks whether a condition is met. The first result is if your comparison is true the second if your comparison is false. Use the if function in combination with the and function and the or function and become an excel expert. The if function the if function is a very flexible function.
To use the if excel worksheet function select a cell and type. We can also use the if function to evaluate a single function or we can include several if functions in one formula. For example take a look at the if function in cell d2 below. You can use it whenever you need to test a condition and take an action based on the result.
This is the proper syntax of the if then function. We also point out one of.