The syntax of an Excel function refers to the layout and order of the function and its arguments.
All functions in Excel begin with the equal sign (= ) followed by the function's name - such as SUM, COUNT, or ROUND.
A function's arguments refer to all the data or information required by a function. These arguments must be entered in the correct order.
The IF function, for example, requires three arguments in the following order:
- the logic test argument
- the value if true argument
- the value if false argument
If these are placed in a different order, the function will return an error message or give you an answer you were not expecting.
In addition to the order of arguments, the syntax also refers to the separators between the arguments. Most functions, including the IF function, use the comma as a separator.
The syntax of the IF function is:
=IF(logic test, value if true, value if false)
Note: Since the syntax of the IF function requires a comma to separate the three arguments of the function, you cannot use a comma as a separator in numbers greater than a thousand. If you do, Excel gives you an error message.