Video není dostupné.
Omlouváme se.
15 IF Statement Examples in Excel - Simple to Advanced - Workbook Included
Vložit
- čas přidán 20. 02. 2018
- VBA/Macros Course (40% Discount): www.teachexcel...
Excel Forum: www.teachexcel...
Excel File: www.teachexcel...
15 different examples of using the IF statement function in Microsoft Excel.
This includes examples that range from simple to complex and includes many different scenarios that will show you the ways that you can use the IF statement to make your spreadsheets better and more advanced.
You will learn how to use comparison operators, text, numbers, other functions and even other IF statements within IF statements.
This tutorial does include Excel files so that you can work along with it - click the link at the top of the description to download it.
VBA/Macros Course (40% Discount): www.teachexcel.com/vba-course-update.php?src=youtube_pinned_comment_I7p6Hzap4qo
Can we output a formula if true or false? Example would be something like this...How could I make this formula work? =IF(LEN(A2)="111"),MID(A2,43,16)IF(LEN(A2)="58"),RIGHT(A2,16)IF(LEN(A2)="25"),MID(A2,8,16),RIGHT(A2,16)) ?
This is by far the most well explained IF statement I have seen.
You have no idea how much this video has helped me, less than 2mins in i already got what I've been looking for!
Keep up the good job, just followed.
Your comfortable pace and stepwise presentation made the learning process a breeze.
I'm really glad you think so!!!! :)))
I am very lucky to view your videos, very informative, lucid, simple , revealing, thought provoking and realistic. Noble and great job indeed. Great Salute to my Excel teacher/Guru.
Thank you so much for your kind words! It means a lot :)))
15 If Statement Examples in Excel: A Comprehensive Guide with a Free Workbook
If statements are a fundamental aspect of Excel, allowing you to automate tasks and make decisions based on specific conditions. In this guide, we'll explore 15 simple to advanced if statement examples in Excel, along with a free workbook to practice with.
1. Basic IF Statement
An IF statement evaluates a given condition and returns a specific value if the condition is true, and another value if it's false.
Example: =IF(A1>10,"Greater","Less")
2. Nested IF Statements
You can use multiple IF statements to create more complex conditions.
Example: =IF(A1>10,"Greater",IF(A110,B1="Yes"),"Match Found","No Match")
4. IF with AND Condition
Combine multiple conditions using AND.
Example: =IF(AND(A1>10,B1="Yes"),"Match Found","No Match")
5. Counting Cells Based on Conditions
Count the number of cells that meet specific conditions.
Example: =COUNTIF(A1:A10, ">10")
6. Summing Cells Based on Conditions
Sum the values in cells that meet specific conditions.
Example: =SUMIF(A1:A10, ">10")
7. Conditional Formatting
Apply formatting to cells based on conditions.
Example: Highlight cells with a value greater than 10.
8. Data Validation
Restrict data entry based on specific conditions.
Example: Allow only values between 1 and 10 in a cell.
9. Using IF with VLOOKUP
Combine IF statements with VLOOKUP to perform more complex lookups.
Example: Look up a value in a table and return a specific message based on the result.
10. IF with Time-Based Conditions
Create time-based conditions using Excel's TIME function.
Example: Return "Morning" if the time is between 6 AM and 12 PM.
11. IF with Date-Based Conditions
Create date-based conditions using Excel's DATE function.
Example: Return "Today" if the date is the same as the current date.
12. Using IF with SUMIFS
Combine IF statements with SUMIFS to perform more complex sums based on multiple conditions.
Example: Sum the values in cells that meet multiple conditions, such as a specific category and date range.
13. Creating Custom Error Messages
Use IF statements to display custom error messages when specific conditions are met.
Example: Display "Invalid Input" if a cell contains text instead of a number.
14. Creating Conditional Dropdown Lists
Create dynamic dropdown lists based on specific conditions.
Example: Show a list of available options based on a user's selection in another cell.
15. Advanced Fuzzy Lookup with IF
Perform fuzzy lookups using IF statements to match similar values in a dataset.
Example: Find the closest match for a given value in a list of names.
To practice these examples, download the free workbook provided with this guide. This resource will help you master Excel's if statements and enhance your overall Excel skills.
I had a difficult time learning IF formula. This video helped a lot! Thanks!
I never get bored of watching this when I need to re-cap on excel !🧐🇬🇧🤔👍🏻❤️🤓🤓🤓🤝🤝🤝💪🏻💪🏻💪🏻
Very good explanations
thank you
The best on this I have seen. Crystal clear as well. well done
Great verbal presentation. Nice pace and repetitiveness; easy to listen to.
thank you sir. working on a project and my manager expects it shortly. your video is a lifesaver. Cheers!
I am very glad to hear it!!! :) And if you ever get stuck you can always ask in our forum and upload sample files and more: www.teachexcel.com/talk/microsoft-office?src=yt_comment
Amazing video. You have explained every step in details with evidence. Thanks a lot.
really u r mindblowing no words to thanks u the content u provide in a single video is above all very appreciated
Thanks you Sir. Clarity explanation, supports me lot
Thank you. This presentation really helped me figure out the formula for my nested IF and Sum function homework that has kept me up all night trying to figure it out. but now I know to add three brackets ))) afterward and it worked. so I ended up having something that looks like these =IF(SUM(C9:H9)=0,0,(SUM(C9:H9))) WHICH I NEVER TAUGHT ABOUT. thank you.
You're very welcome! I'm glad I could help! If you ever need help in the future, feel free to ask on our forum and someone will be around to help out :) www.teachexcel.com/talk/microsoft-office?src=yt_comment
*FIRST!* ♥ Seriously... before I used the Function wizard as a crutch to build IF statements and make sure the syntax was right. I'm gaining in confidence now and certainly wouldn't use the wizard to build simpler IF statement formulas. Thanks for sharing your knowledge!
I'm glad this helped! :) I think I will do a more complex set of IF statements in the near future as well and hopefully you'll find that useful as well
Subbed & Notified!
This really helped me to prepare for my finals
Thank you❤
Thank you so much! Explanation is great and voiceover carries well.
thanks for this, i found what i was looking for, nested IF statements 👍🏻❤️ (the formula below, checks E6, & compare it w/ certain range of Nos., and outputs a text appropriate for that)
=IF(AND(E6>19,E670,E6128,E6180,E6248,E6
Beautiful explanation.... 👍
Great video! Thank you. 📊
Love the content of this video and your way of teaching! Thanks for the video which gave me inspiration for my own classes (I give basic Excel training to students) 😊
If I can only ask my school to replace my teacher right now, I would chose you
You are incomparable the way you show on your tutorial video.
Very well explained.
In the second to last example, it seems a little odd to have both IF functions display "Bad" if the result of their respective logical test is false. By doing this, it is not immediately apparent which IF function cause "Bad" to be displayed.
exactly, i would recommend in that last nested IF to return three distinct answers so you could trace back
Amazing and very helpful
if A1 < 0 and A1 > 0? for conditional formating means if cell is less than 0 and same cell may be other time more than 0?
thanks
This was very helpful and gave me a much better understanding... thank you for taking the time to post this.🙏🏼
You're welcome! I'm glad you liked it :)
Hi wondering if you can help, I'd like to create a statement for my issues and risks template. It issue and risk should be given a ID automatically. So if I have two risks I would like them to be to given the id's 1&2 the same for an issue. What formula would I use please
?
Awesome video. Question, can you include Highlights in the "If" formula. For example, "If X = False, then highlight red" ?.
Nice question!
Thank you for your videos Sir. Your videos gave me a much needed refresher on these functions which are very powerful once you know how to use them efficiently. Much much appreciated.
You're very welcome!!! :)
Very helpful 😍😍
This information is very useful I have gain a better understanding, thank you
*Need Help* If I wanted to add a number in a cell, but wanted the field next to it to highlight, would that be an If Formula, or something different? *Just had to ask
I'd recommend making three distinct answers for each IF statement on the final nested IF statement so you could see how each answer is returned. otherwise, great video
That was my suggestion too. Instead of 'bad' maybe 'bad', 'badd', and then 'baddd' just to be able to figure out where the false is occurring.
thanks so much for this sir i just have a difficulty if in a single cell i will find multiple criteria and will display multiple valu, is if function still be in use?
Awesome video... Thanks 👍😇
I have a estimating spreadsheet that I would like to find out if this is even possible
Question: Can excel allow a drop down menu where you can choose one from 3-5 of different material categories?
Question: If so, when a selection is made then it changes the options available in the next drop down menu based on the previous selection
Question: Can I get up to date pricing from several suppliers (3) in real time where Excel compares the difference and inputs the lowest or highest cost into the sheet
Example if a sheet of plywood is 29.00 and one of the three suppliers has pricing at 26.00 and I enter that I need 20 sheets would it price out correctly
Question: how can I enter the area of a roof and based on the prior formulas would excel create a price sheet or materials list without having to input each value separately? Example: a 30 year shingle has 3 bundles per 100 sq ft but a 40 year shingle has 4 bundles per 100 square ft. Can excel determine which of the two options 3 or 4 to choose based upon the initial questions answered in the drop down menus?
I Love your Experience ,Egypt
18:17 it would seam to me that you could just do a 3 way and funktion there? I would say most nestled if fucntions can be replaced with and or or. And if you are a but smart with it, reversing the sign (say from equal to not equal) can solve it if it a miss match.
Really to make the code easier to read and also operate faster. (And yes, speed can actually be a issue sometimes)
Hello, are you still teaching Excel, I have a problem trying to use an IF statement in a dropdown lists that contains few dependable cells that the same time will display all results in one cell. Do you think that you can help me with this?
The tutorial was spot on and helped a lot! I am trying to make the value of a cell change based off of another cell but I’m dealing with dates! So, for example I have one column that gives the status of an individual “expired” or “certified” but I want these cells to change automatically based off of their certification date listed in a separate column! How can I make the value of the status column cells changed based off of a date in a separate column?
Hi!
Im struggling with the following formula I would like to use.
Column B has got text. With discriptions and names etc.
Column B is in a table called (discription)
For this column I use the =IF(COUNTIF(discription,''*abc*'',''A'',"")
But I want to add another if to this formula for example =IF(COUNTIF(discription,''*123*'',''B'',"")
And 3 to for more IF('s)
Im stuck, hope someone could give some advice ✌️🙏
This is exactly what I was looking for, thankyou!
bless this guy! my teacher is absolute garbage.... this guy made it so easy to understand
Teachers are not garbage. Sometimes some person way of teaching is better.This is something really rude to say garbage about your teacher.
so the question is as such i have a coloum with names of sports so for instance “cricket” “soccer” “chess” “ice hockey” “car race” they want me to use a function so that it’ll show first four words of the single word sports and for the “ice hockey” and “car race” Itll show “ first three letters of first word and first letter of second word” but they want me to use “if” function for it. The coloum that has the names of the sports (both single word and two words” is labelled “sport” and i have to use “if” function, also they said if they add a new name be it “one word” or “two word” sport, the formula i use should produce the desired result? So for if function how to let the system
know that the sports with single words should show first four letters while the ones with two words should show “first words first three letters and second words first letter”
Can't thank you enough for this!!!
You are very welcome! I'm glad I could help :))
Great video. I hope I'm on the right track, but I'm not sure what my false if values would be in my scenario....So my goal is to keep track of a multitude (250+) of invoices, receipts and payments: (A column or 1) is an entered date, (B column or 2) has the vendor name, (C column or 3) has the $ amount, (D column or 4) has a drop list of subcategories under the main category "fixed", (E Column or 5) has another different drop list of subcategories under another main category "expense", and so on.....can I use the "if" function for different possible choices of entries in a specific row to different tabs within the same worksheet, then use a loop function for the next row of entries? Or would a vlookup be more appropriate? Ex. =if(5,4="fixed",go to "fixed" tab),(5,5="expense",go to "expense" tab),(5,6="income", go to "income" tab),(5,7="loans", go to "loans" tab) Thank you for your clarification :))
very helpful
Haii
For example Diameter 20 with +/-0.020 and measured value is 19.970/19.980. Here lower value have -0.010mm deviation. Same this how can get in excel?
It will be useful to me in work
Please help
if u had a name col. a gender col.an age column and a range showing dates when persons were present. how can u find the for eg the no of males in 15-19, category or no of females in 15-19 catergory, or similarly 20-24 male or female , 25-29 male or female,30-34 male or female, 35-39, or 40 and above male or female?
I am trying to use the IF then statement to find all of the cells in Excel that contain the text "NO GO" in order to create a separate PDF file with the whole line of Information associated with the NO GO cell. IS the IF then statements only used for numerical? or is it possible to use text?
maybe i missed it in this training video, I apologize ahead of time.
can you use the IF function to test color of different cells?
plz make a video account statement from a speific date to a requried date in excell
Can this if function do other thing except true and false.?
Great Tutorial I just one question, I encountered this formula "=IF(N76="OSM","OSM",N76*$O$4)" and was wondering what "OSM" means? Thanks.
A teacher friend of mine asked me if it was possible to create a calculator program in Excel that adds up money denominations. Example: click on a dollar bill graphic and that adds a dollar, then click on a five-dollar bill graphic that adds 5 more dollars to the amount, and so on. She would like coins to be included as well. She has a electronic device called a "Coin-u-lator" that does this but they are expensive for the number of students she has and not a big budget.
Can u please help me to find out that what's the problem with the formula I made to round of (I don't want to use round fn )
=if(right(c9, 1)>=5, c9+10-right(c9, 1), c9-right(c9, 1))
Please help ASAP
Thank you
What if two columns will be interpreted. please help me
Ex. c1 is frustration and e1 is instructional- the interpretation is frustration
if c1 is instructional and e1 is independent- the interpretation is instructional
if c1 is independent and e1 is independent- the interpretation is independent
I have two cells to be interpreted please help me out.
Please suggest a formula if date change than amount will be automatically changed.
Thank you
Hi,
I am preparing my inventory sheet and I have 2 columns In-stock inventory and on the way inventory. I wanna use 2 statements in Stock, on the way and out of stock. Please help
Ask on the forum and upload sample file please: www.teachexcel.com/talk/microsoft-office?src=yt_comment
Hi iam trying to practise excel through your tutorials, they are very helpful, thank you so much.
Help, my laptop does not have a source icon,
I'm not exactly sure what the issue is. Maybe your version of Excel is different than mine or you need to repair it? Post this in our forum and explain exactly what the issue is and we can troubleshoot the issue - I cannot usually see replies to my comments here.
Last example was nice, never used Nested IF like that. I used a lot of nested IF but I always typed value_if_true for first IF as well
Glad to offer some new tips! :) If you have anything to share with IF statement feel free to post it and I'll see if it can go in the next video :)
Actually I wrote wrong it wasn't nested IF it was a simple IF with IF statement in value if true :-) I would recommend to show IFS function instead of Nested IF for those who use O365
If c3, c7
Well done great job thanks
Hi, thanks pls help how to put another cell (not the text specific) as final true argument
Good day i struggle to find the visual basic on my laptop please assist. And thank you so much for this vedios, they are of great help to me😘
Thanks
Fantastic tutorial
Can you help with this function, =IF(J3 greater than 10,"1",IF(J3 is greater than 10 or less than 15,"2",IF(J3 greater than 15 or less than 20,"3",IF(J3 greater than 20 or less than 25,"4",IF(J3 greater than 25,"5")))))
HAVE a problem with this: A SUBJECT HAS THREE PAPERS SAY P1: 45, P2: 30 P3: 81, IF They a student scores an F9 in any of the subject papers, he or she automatically qualifies for an "O" if the rest of the papers are Credits, otherwise the student gets the avaerage of the points per paper. help me the if/ifs function
Is it possible to link the cell for the "value_if_true"?
With the cery first activities, IT DOES NOT WORK. I get a message that there is a problem with the formula and Excel Has problem with the = sign😢
Can and be used in a count if function
so exciting
I have a very tricky if formula. Could you help
How is this workbook included? I want to learn if formula using cells in other workbook sheets.
I tried to use your solution but they didn't work on my Office 2019. Between each value I couldn't figure out what the problem was. Finally I did found a solution. I must use the ; sign instead of the , sign. I don't know why this happens but maybe because I'm living in Europe or by some other stupid reason. But thanks anyway for these IF argument solutions.
very useful, thanks
Some segments in the video are stamped not adjacent to each other
hello sir. this tutorial is great! can you combine index match with if function?
Yes, in about a million different ways. Search my tutorials on here or on teachexcel.com for some advanced tutorials on this topic and I'm sure you'll find something. If you have specific questions, just ask in our forum: www.teachexcel.com/talk/microsoft-office?src=yt_comment
When I seen your file on Excel mobile, (on windows phone) I noticed that I needed to use =if(A1>=30;"cool";"Not cool")
Thanks a lot
Hii
Can you plz upload some of sumif function or more advance logical functions it will really help me
Hi , can you please help me, i need to add vat automatically to my supliers , so if supplier name contains ( google ) for example , i need the excel to apply %20 vat automatically to it
Sounds like you just need a lookup function and table. Go ahead as upload a sample file and kindly ask for some help with specifics in our forum. TeachExcel Forum: www.teachexcel.com/talk/microsoft-office?src=yt_comment
Thank you for your help
thank you for the video!!
I want to be able to run .30 to 1 on excel, please how can I do that ?
Please anybody help How can i use if formula for A1>15"A+",A1>12"A", A1> 10"B+"......
How do I make an If statement using cells that have a date and number? For example, If this anniversary date arrives then these two cells revert back to zero.
Depends how your date is formatted, but usually a regular IF statement works if you have both dates in their own cells. If you want to be more specific, ask on our forum and you can also upload a sample file. www.teachexcel.com/talk/microsoft-office?src=yt
OWP+++ excellent.
very helpful for Excel class. ty, nj
Glad you like it:)
if you please assist me for an workbook to distribute the available of currency note to each dept. employee ,[ domination sheet for salary ]
You should ask this in our forum: www.teachexcel.com/talk/microsoft-office?src=youtube
Hello
I wrote the following - =IF(and(N29N36),P35,"false") in cell N30 and Cell P35 has the Text STABLE in it
in cell n29 is the value 4.69% in cell n34 is the value 6.00% in cell n36 is the value -6.00%
Every thing I can find and follow tells me that in cell N30 I should get the word STABLE
All I get is the Formula shown in the box
What an I doing wrong?
What I want is the following, but I gave up on that
=if(or(N29>N34),P34,""),or(N29>N36)P36,""),and(n29=n34),P35,""))
but
Maybe there is a BETWEEN that I need to look into too
James
Please ask questions like this on our forum, where it is much easier to help: www.teachexcel.com/talk/microsoft-office?src=yt
Expected output is all the same True, false, good, bad, what if i want to return a number. ie. if E2=M, return 240 or if E2=S, return 120, etc
use IFS() or nested IF statements. =IF(condition,240,IF(condition,120,"No value")) - if you are still not clear about it, just ask in our forum and provide a sample of the issue. www.teachexcel.com/talk/microsoft-office?src=yt_comment
i need 3 "if functions" in 1 cell. if 0-120, 121-240, 241-360. 0-120 = 1, 121-240 = 2 & 241-360 = 3. How do i type that into excel ?
You probably want to use a vlookup to do this otherwise, just nest the IF statements - give it a try and post a question on our forum and someone will be happy to help.
So if I have two cells $100 and $200 and I want a cell to say "IF" $200 >$100 the cell will fill -$100?
Can i use 'If', 'vlookup' and 'and' together?
Yes. You can basically nest all of the functins and formulas! Go ahead and give it a try and I think you will be pleasantly surprised :)
Interesting