{"id":234,"date":"2014-09-24T00:03:00","date_gmt":"2014-09-23T22:03:00","guid":{"rendered":"https:\/\/www.myexcelonline.com\/?p=234"},"modified":"2024-05-30T16:15:25","modified_gmt":"2024-05-30T14:15:25","slug":"if-function-introduction","status":"publish","type":"post","link":"https:\/\/www.myexcelonline.com\/meo-staging\/blog\/if-function-introduction\/","title":{"rendered":"IF Function: Introduction"},"content":{"rendered":"<p><em><strong>What does it do? <\/strong><\/em><\/p>\n<p>It returns a value that you set if a condition is met, and a value if it is not met<\/p>\n<p><em><strong>Formula breakdown: <\/strong><\/em><\/p>\n<p>=IF(<span style=\"color: #0000ff;\">Logical Test<\/span>,<span style=\"color: #ff6600;\">Value if True<\/span>,<span style=\"color: #008000;\">Value if False<\/span>)<\/p>\n<p><em><strong>What it means: <\/strong><\/em><\/p>\n<p>=IF(<span style=\"color: #0000ff;\">The condition to be checked<\/span>, <span style=\"color: #ff6600;\">Value to be shown if the condition is met<\/span>, <span style=\"color: #008000;\">Value to be shown if condition is not met<\/span>)<\/p>\n<hr \/>\n<p>The <strong>IF function<\/strong> is probably one of the most used Excel functions because it is easy to understand and very flexible when you apply it to real life situations.<\/p>\n<p>Here I will show you a couple of ways that you can use the\u00a0<strong>IF function<\/strong> to get you up and going.<\/p>\n<div class=\"after-post-box\">\n<p class=\"line-two\"><a class=\"IRPP_minimalist icon-download button small\" href=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/If.xlsx\" target=\"_blank\" rel=\"noopener noreferrer\" data-leadbox=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/If.xlsx\" data-leadbox-id=\"147284833f72a2:12f08263ab46dc\"><span class=\"ctaText px-3 text-capitalize\">Download excel workbook<i class=\"fa fa-download\"><\/i><\/span><span class=\"postTitle px-3\">If.xlsx<\/span><\/a><\/p>\n<\/div>\n<p>We want to show a <strong>Bonus<\/strong> value if <strong>sales are bigger than $3000<\/strong>, and <strong>No Bonus<\/strong> is shown if this condition is not met. Afterwards let&#8217;s try computing the <strong>10% bonus<\/strong>!<\/p>\n<p><span style=\"color: #ff0000;\"><strong>STEP 1:\u00a0<\/strong><\/span>We need to enter the <strong>IF function<\/strong> in a blank cell:<br \/>\n<code><span style=\"color: #0000ff;\">=IF(<\/span><\/code><br \/>\n<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-9756\" title=\"IF Function: Introduction\" src=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if1.png\" alt=\"IF Function: Introduction\" width=\"697\" height=\"435\" srcset=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if1.png 697w, https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if1-300x187.png 300w\" sizes=\"(max-width: 697px) 100vw, 697px\" \/><\/p>\n<p>&nbsp;<\/p>\n<p><strong><span style=\"color: #ff0000;\">STEP 2:<\/span> <\/strong>The <strong>IF<\/strong> arguments:<\/p>\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_57_1 counter-flat ez-toc-counter ez-toc-transparent ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title \" >Table of Contents<\/p>\n<span class=\"ez-toc-title-toggle\"><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li><a href=\"#\" class=\"scroll-to-download\">Free Practice Workbook<\/a><\/li><li class='ez-toc-page-1'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/www.myexcelonline.com\/meo-staging\/blog\/if-function-introduction\/#Logical_test\" title=\"Logical_test\">Logical_test<\/a><\/li><li class='ez-toc-page-1'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/www.myexcelonline.com\/meo-staging\/blog\/if-function-introduction\/#Value_if_true\" title=\"Value_if_true\">Value_if_true<\/a><\/li><li class='ez-toc-page-1'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/www.myexcelonline.com\/meo-staging\/blog\/if-function-introduction\/#Value_if_false\" title=\"Value_if_false\">Value_if_false<\/a><\/li><li class='ez-toc-page-1'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/www.myexcelonline.com\/meo-staging\/blog\/if-function-introduction\/#Logical_test-2\" title=\"Logical_test\">Logical_test<\/a><\/li><li class='ez-toc-page-1'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/www.myexcelonline.com\/meo-staging\/blog\/if-function-introduction\/#Value_if_true-2\" title=\"Value_if_true\">Value_if_true<\/a><\/li><li class='ez-toc-page-1'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/www.myexcelonline.com\/meo-staging\/blog\/if-function-introduction\/#Value_if_false-2\" title=\"Value_if_false\">Value_if_false<\/a><\/li><\/ul><\/nav><\/div>\n<h2><span class=\"ez-toc-section\" id=\"Logical_test\"><\/span><em>Logical_test<\/em><span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p><strong>What is your condition? <\/strong><\/p>\n<p>Sales Rep has sold more than 3000 dollars.<br \/>\n<code>=IF(<span style=\"color: #0000ff;\">D15&gt;3000,<\/span><\/code><br \/>\n<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-9757\" title=\"IF Function: Introduction\" src=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if2.png\" alt=\"IF Function: Introduction\" width=\"537\" height=\"292\" srcset=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if2.png 537w, https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if2-300x163.png 300w\" sizes=\"(max-width: 537px) 100vw, 537px\" \/><\/p>\n<h2><span class=\"ez-toc-section\" id=\"Value_if_true\"><\/span><em>Value_if_true<\/em><span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p><strong>What value should be displayed if the condition is true? <\/strong><\/p>\n<p>We want &#8220;<strong>Bonus<\/strong>&#8221; to be displayed<br \/>\n<code>=IF(D15&gt;3000, <span style=\"color: #0000ff;\">\"Bonus\",<\/span><\/code><br \/>\n<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-9758\" title=\"IF Function: Introduction\" src=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if3.png\" alt=\"IF Function: Introduction\" width=\"528\" height=\"281\" srcset=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if3.png 528w, https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if3-300x160.png 300w\" sizes=\"(max-width: 528px) 100vw, 528px\" \/><\/p>\n<h2><span class=\"ez-toc-section\" id=\"Value_if_false\"><\/span><em>Value_if_false<\/em><span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p><strong>What value should be displayed if the condition is false? <\/strong><\/p>\n<p>We want &#8220;<strong>No Bonus<\/strong>&#8221; to be displayed<br \/>\n<code>=IF(D15&gt;3000, \"Bonus\", <span style=\"color: #0000ff;\">\"No Bonus\")<\/span><\/code><br \/>\n<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-9759\" title=\"IF Function: Introduction\" src=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if4.png\" alt=\"IF Function: Introduction\" width=\"551\" height=\"281\" srcset=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if4.png 551w, https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if4-300x153.png 300w\" sizes=\"(max-width: 551px) 100vw, 551px\" \/><\/p>\n<p>Apply the same formula to the rest of the cells by dragging the lower right corner downwards.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-9760\" title=\"IF Function: Introduction\" src=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if5.png\" alt=\"IF Function: Introduction\" width=\"528\" height=\"299\" srcset=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if5.png 528w, https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if5-300x170.png 300w\" sizes=\"(max-width: 528px) 100vw, 528px\" \/><\/p>\n<p><span style=\"color: #ff0000;\"><strong>STEP 3:<\/strong> <\/span>Let us now aim to give the <strong>10% Bonus!<\/strong><\/p>\n<p>The <strong>IF<\/strong> arguments:<\/p>\n<h2><span class=\"ez-toc-section\" id=\"Logical_test-2\"><\/span><em>Logical_test<\/em><span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p><strong>What is your condition? <\/strong><\/p>\n<p>Sales Rep has sold more than 3000 dollars.<br \/>\n<code>=IF(<span style=\"color: #0000ff;\">D15&gt;3000,<\/span><\/code><br \/>\n<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-9761\" title=\"IF Function: Introduction\" src=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if6.png\" alt=\"IF Function: Introduction\" width=\"572\" height=\"284\" srcset=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if6.png 572w, https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if6-300x149.png 300w\" sizes=\"(max-width: 572px) 100vw, 572px\" \/><\/p>\n<p>&nbsp;<\/p>\n<h2><span class=\"ez-toc-section\" id=\"Value_if_true-2\"><\/span><em>Value_if_true<\/em><span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p><strong>What value should be displayed if the condition is true? <\/strong><\/p>\n<p>We want give a <strong>10% bonus based on sales<\/strong><br \/>\n<code>=IF(D15&gt;3000, <span style=\"color: #0000ff;\">D15*10%,<\/span><\/code><br \/>\n<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-9762\" title=\"IF Function: Introduction\" src=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if7.png\" alt=\"IF Function: Introduction\" width=\"609\" height=\"278\" srcset=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if7.png 609w, https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if7-300x137.png 300w\" sizes=\"(max-width: 609px) 100vw, 609px\" \/><\/p>\n<h2><span class=\"ez-toc-section\" id=\"Value_if_false-2\"><\/span><em>Value_if_false<\/em><span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p><strong>What value should be displayed if the condition is false? <\/strong><\/p>\n<p>Then no bonus amount should be given, type in 0<br \/>\n<code>=IF(D15&gt;3000, D15*10%, <span style=\"color: #0000ff;\">0)<\/span><\/code><br \/>\n<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-9763\" title=\"IF Function: Introduction\" src=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if8.png\" alt=\"IF Function: Introduction\" width=\"606\" height=\"282\" srcset=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if8.png 606w, https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if8-300x140.png 300w\" sizes=\"(max-width: 606px) 100vw, 606px\" \/><\/p>\n<p>Apply the same formula to the rest of the cells by dragging the lower right corner downwards.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-9764\" title=\"IF Function: Introduction\" src=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if9.png\" alt=\"IF Function: Introduction\" width=\"545\" height=\"300\" srcset=\"https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if9.png 545w, https:\/\/www.myexcelonline.com\/meo-staging\/wp-content\/uploads\/2014\/09\/if9-300x165.png 300w\" sizes=\"(max-width: 545px) 100vw, 545px\" \/><\/p>\n<p>You now have all of results!<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>What does it do? It returns a value that you set if a condition is met, and a value if it is not met Formula breakdown: =IF(Logical Test,Value if True,Value if False) What it means: =IF(The condition to be checked, Value to be shown if the condition is met, Value to be shown if condition [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":17386,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"cos_headline_score":0,"cos_seo_score":0,"cos_headline_text":"IF Function: Introduction","cos_headline_has_been_analyzed":false,"cos_last_analyzed_headline":[],"om_disable_all_campaigns":false},"categories":[12,3,283],"tags":[43,47],"acf":[],"_links":{"self":[{"href":"https:\/\/www.myexcelonline.com\/meo-staging\/wp-json\/wp\/v2\/posts\/234"}],"collection":[{"href":"https:\/\/www.myexcelonline.com\/meo-staging\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.myexcelonline.com\/meo-staging\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.myexcelonline.com\/meo-staging\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.myexcelonline.com\/meo-staging\/wp-json\/wp\/v2\/comments?post=234"}],"version-history":[{"count":0,"href":"https:\/\/www.myexcelonline.com\/meo-staging\/wp-json\/wp\/v2\/posts\/234\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.myexcelonline.com\/meo-staging\/wp-json\/wp\/v2\/media\/17386"}],"wp:attachment":[{"href":"https:\/\/www.myexcelonline.com\/meo-staging\/wp-json\/wp\/v2\/media?parent=234"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.myexcelonline.com\/meo-staging\/wp-json\/wp\/v2\/categories?post=234"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.myexcelonline.com\/meo-staging\/wp-json\/wp\/v2\/tags?post=234"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}