Mar 11, 2016
If you use Excel through an Office 365 subscription or you use Excel Online or Excel Mobile, then you can take advantage of two new worksheet functions: IFS() and SWITCH()
IFS()
IFS() can make creating nested IF() functions unnecessary as IFS() lets you test for multiple conditions. The first one to return TRUE wins.The syntax for the function is:
=IFS(logical_test1, value_if_true1, [logical_test2, value_if_true2], [logical_test3, value_if_true3],…)
Note: Up to 128 logical tests can be incorporated into an IFS() function
Here is an example of its use:
Grades converted from score out of 100 to A, B, C, D or F
=IFS(A1>89,"A",A1>79,"B",A1>69,"C",A1>59,"D",TRUE,"F")
If A1 contains 92 then IFS() will return “A”
If A1 contains 60 then IFS() will return “D”
SWITCH()
The SWITCH() function compares a value against a list of values and returns the first matching value. If there is no match, an optional default value may be returned.
The syntax for the function is:
Note: Up to 126 values and results can be incorporated into a SWITCH() function
Here is an example of its use:
If A2 contains 2 then SWITCH() will return “Tuesday”
If A2 contains 6 then SWITCH() will return “Weekend”
For more of Excel’s worksheet functions, take a look at New Horizons’ Excel courses.
How do your Excel skills stack up?
Test NowNext up:
- The Change Cycle
- Persistent chat server role in Skype for Business
- Talking Tactics
- Excel Keyboard Shortcuts
- Leaping over communication hurdles
- More PowerShell Constructs and Loop Management
- Corruption found in Professional Development training company
- Using a model in your AngularJS form
- Why is it so hard to apologise?
- Fundamentals of Microsoft Azure
Previously
- PowerShell Profiles - Have it your way (Part 2)
- Do you Kanga?
- Windows 10 Command Prompt Shortcut Keys
- Skype for Business Server Architecture
- My thoughts on the Moto 360 SmartWatch
- How-To Series: Photoshop CC Intelligent Upsampling
- The Agreement Frame: Solving Complex Arguments
- Tips and Tricks with Nintex Forms
- 3 Simple Pie Chart Tricks
- Streaming Xbox One to Windows 10