+ Reply to Thread
Results 1 to 2 of 2

Understanding logical_test entry in IF statement

Hybrid View

  1. #1
    Registered User
    Join Date
    04-11-2013
    Location
    Englewood, FL
    MS-Off Ver
    Excel for Mac V16.19
    Posts
    11

    Understanding logical_test entry in IF statement

    see below…

    =IF((C5>=38)*(C5<=40),B5+1,IF((C5<=$V$61)*(C5<>""),B5-$W$63,IF((B5<>"")*(C5=""),B5,IF((B5="")*(C5=""),""))))

    I don't know how the "logical_test"(s) shown below from the above IF statements are read... ( aka: determined to be True or False)

    (C5>=38)*(C5<=40)

    (C5<=$V$61)*(C5<>"")

    (B5<>"")*(C5="")

    (B5="")*(C5="")

    thanks...

  2. #2
    Forum Guru benishiryo's Avatar
    Join Date
    03-25-2011
    Location
    Singapore
    MS-Off Ver
    Excel 2013
    Posts
    5,156

    Re: Understanding logical_test entry in IF statement

    hi AndyL446, welcome to the forum. Excel treats TRUEs as 1s & FALSEs as 0s. each of those in brackets are logical tests, which will give you TRUE or FALSE. so there can be these scenarios:
    TRUE * TRUE
    TRUE * FALSE
    FALSE * TRUE
    FALSE * FALSE

    anything that has FALSE is 0 & anything multiplied by 0 is 0. hence, only when both are TRUE will it execute the TRUE result you input. your first logical test for eg.
    (C5>=38)*(C5<=40)
    only when C5 is greater or equals to 38 AND C5 is lesser or equals to 40, then it will take B5 + 1. hope that helps

    Thanks, if you have clicked on the * and added our rep.

    If you're satisfied with the answer, click Thread Tools above your first post, select "Mark your thread as Solved".

    "Contentment is not the fulfillment of what you want, but the realization of what you already have."


    Tips & Tutorials I Compiled | How to Get Quick & Good Answers

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1