What is the use of AND function?

AND Function in Excel tests two or more conditions to see if they are all true.It returns TRUE if all conditions are TRUE, returns FALSE if any of the conditions is FALSE. AND function would be used in conjunction with another function such as IF function.

What is the syntax of AND function?

AND Function in Excel- Syntax

AND(condition1,condition2,..)

AND Function in Excel – Examples

AND Function in Excel- Example 1

Example 1: Returns TRUE as both conditions are satisfying
Example 2: Returns False asthe second condition is not satisfying
Example 3: Returns FALSE as both conditions are not satisfying
Example 4: Returns TRUE as both conditions are satisfying
Example 5: Returns TRUE as all 3 conditions are satisfying

Example on AND function in conjunction with IF Function

AND Function in Excel- Example 2

Example 6: AND Returns TRUE as both conditions are satisfying, IF retuns ‘Correct’ as the condition is TRUE
Example 7: AND Returns FALSE as the second condition is not satisfying, IF retuns ‘Not Correct’ as the condition is FALSE

VBA example on AND function

AND function is also available in VBA, following is the example code:

Dim sOutout As String
Dim iVal1 As Integer
Dim iVal2 As Integer
iVal1 =2100
iVal1 =3500

If iVal1 > 2000 AND iVal2 >= 3000 then
sOutout=”Correct”
Else
sOutout=”Incorrect”
End If

Output: as both the conditons are TRUE value of sOutout will be “Correct”

Reference:

Please refer the below article for more Logical Excel functions.
Logical Excel Formulas

Please refer the below article for more Excel Functions.
Excel Formulas | Home

Premium Project Management Templates

120+ Professional Project Management Templates!

A Powerful & Multi-purpose Templates for project management. Now seamlessly manage your projects, tasks, meetings, presentations, teams, customers, stakeholders and time. This page describes all the amazing new features and options that come with our premium templates.

PREMIUM TEMPLATES
LIMITED TIME OFFER
ON SALE80% OFF
BROWSE ALL TEMPLATES

Advanced Project Planning Templates

Excel Templates

VIEW DETAILS

120+ Project Management Templates Pack

Excel | PowerPoint | Word

VIEW DETAILS

ULTIMATE RESOURCE MANAGEMENT TEMPLATE

Excel Template

VIEW DETAILS

50+ Essential Project Management Templates

Excel | PowerPoint | Word

VIEW DETAILS

Project Portfolio Management Templates

Excel | PowerPoint Templates

VIEW DETAILS

50+ Excel Project Management Templates

Excel Templates

VIEW DETAILS

By Published On: March 10th, 2013Categories: Excel FormulasTags:

Share This Story, Choose Your Platform!

About the Author: Valli

Excel VBA Developer having around 8 years of experience in using Excel and VBA for automating the daily tasks, reports generation and dashboards preparation. Valli is sharing to helps us automating daily tasks.

Leave A Comment