+ Reply to Thread
Results 1 to 4 of 4

Excel 2007 : If(and(or

  1. #1
    Registered User
    Join Date
    03-07-2012
    Location
    south carolina, USA
    MS-Off Ver
    Excel 2007
    Posts
    10

    If(and(or

    I have three columns, A, B, and C. What I am trying to do is to make column C represent the "statuses" of columns A and B (per row of course). There are three possible outcomes in columns A and B. They can both be blank, one or the other can have a date (but never both columns with a date at the same time), or one of the columns will have the word "rejected" (again, never will both of the columns have "rejected" at the same time).

    This is what I need in column C;

    If both columns A and B are blank then column C needs to say "No Feedback"
    If either column A or B have a date then column C needs to say "Approved"
    If either column A or B have the word "rejected" then column C needs to say "Rejected"

    I have tried a few of my own if(and(or combinations but am getting confused becasue of all of the possible outcomes and lengthy formulas. Any help would be appreciated. Thanks.

  2. #2
    Forum Expert
    Join Date
    07-16-2010
    Location
    Northumberland, UK
    MS-Off Ver
    Excel 2007 (home), Excel 2010 (work)
    Posts
    3,054

    Re: If(and(or

    Working with row 1:

    =IF(AND(A1="",B1=""),"No Feedback",IF(OR(A1="Rejected",B1="Rejected"),"Rejected","Approved"))

    This assumes that A1 & B1 will always be blank, or be "Rejected" or contain a date. Other values will cause the formula to spit out "Approved", even if the values in there aren't dates.

  3. #3
    Forum Expert
    Join Date
    12-15-2009
    Location
    Chicago, IL
    MS-Off Ver
    Microsoft Office 365
    Posts
    3,177

    Re: If(and(or

    I cannot guarantee the date check will work 100% accurately, but the rest should be good.

    =IF(AND(ISBLANK(A1),ISBLANK(B1)),"No Feedbacks",IF(OR(ISNUMBER(A1),ISNUMBER(B1)),"Approved",IF(OR(PROPER(A1)="Rejected",PROPER(B1)="Rejected"),"Rejected","")))

  4. #4
    Registered User
    Join Date
    03-07-2012
    Location
    south carolina, USA
    MS-Off Ver
    Excel 2007
    Posts
    10

    Re: If(and(or

    Thank you Andrew-R, works perfect.

+ 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