+ Reply to Thread
Results 1 to 9 of 9

IFERROR AND formula?

  1. #1
    Forum Contributor
    Join Date
    10-28-2014
    Location
    Sydney
    MS-Off Ver
    Professional 2010
    Posts
    151

    IFERROR AND formula?

    Is it possible to do an IFERROR and AND formula? There's 2 possible results for the IFERROR.

    e.g
    IFERROR AND A1="X"
    IFERROR AND A1="Y"

    Thanks

  2. #2
    Forum Expert PaulM100's Avatar
    Join Date
    10-09-2017
    Location
    UK
    MS-Off Ver
    Office 365
    Posts
    2,108

    Re: IFERROR AND formula?

    Probably something like this:

    =IF(AND(ISERROR(B1),A1="X"),1,IF(AND(ISERROR(B1),A1="Y"),2))

  3. #3
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: IFERROR AND formula?

    I think you need to use OR instead of AND
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    If you like my answer please click on * Add Reputation
    Don't forget to mark threads as "Solved" if your problem has been resolved

    "Nothing is so firmly believed as what we least know."
    --Michel de Montaigne

  4. #4
    Forum Contributor
    Join Date
    10-28-2014
    Location
    Sydney
    MS-Off Ver
    Professional 2010
    Posts
    151

    Re: IFERROR AND formula?

    Paul, thanks. Sorry ,I probably shouldve mentioned, the formula goes in A1.

    The true result has to be X1 (when X is true) or Y1 (when Y is true) in cell A1

    AlKey, just saw your post. Im not sure that will work.

    Please note: Im using lookups with ranges and theres no lookup value at the start of the range.

    e.g. LOOKUP(2,1/($B$2:$B10<>""),$B$4:$B10)="X2",A5="X")

    Sometimes between B2:B10 there is no value yet and it produces an error. Its an IF AND formula and requires A5=X or Y also
    Last edited by prudential; 04-25-2018 at 08:46 AM.

  5. #5
    Forum Expert PaulM100's Avatar
    Join Date
    10-09-2017
    Location
    UK
    MS-Off Ver
    Office 365
    Posts
    2,108

    Re: IFERROR AND formula?

    What cell is X? What cell is Y? What should cell should be the error?
    Ar you looking ofr something like:

    =if(and(x="TRUE",iferror(B1)),"X1",if(and(Y="TRUE",iferror(B1)),"Y1","Error"))

  6. #6
    Forum Contributor
    Join Date
    10-28-2014
    Location
    Sydney
    MS-Off Ver
    Professional 2010
    Posts
    151

    Re: IFERROR AND formula?

    IF(AND(LOOKUP(2,1/($B$2:$B4<>""),$B$2:$B4)="X2",$A5="X"),"X1",

    IF(AND(LOOKUP(2,1/($B$2:$B4<>""),$B$2:$B4)="Y2",$A5="Y")),"Y1",

    lets say the formula is in C5 (sorry)
    Last edited by prudential; 04-25-2018 at 08:59 AM.

  7. #7
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: IFERROR AND formula?

    Quote Originally Posted by prudential View Post
    Paul, thanks. Sorry ,I probably shouldve mentioned, the formula goes in A1.

    The true result has to be X1 (when X is true) or Y1 (when Y is true) in cell A1

    AlKey, just saw your post. Im not sure that will work.

    Please note: Im using lookups with ranges and theres no lookup value at the start of the range.

    e.g. LOOKUP(2,1/($B$2:$B10<>""),$B$4:$B10)="X2",A5="X")

    Sometimes between B2:B10 there is no value yet and it produces an error. Its an IF AND formula and requires A5=X or Y also
    It is yours direct responsibility to provided accurate requirements. The example in your original post as totally misleading.

  8. #8
    Forum Contributor
    Join Date
    10-28-2014
    Location
    Sydney
    MS-Off Ver
    Professional 2010
    Posts
    151

    Re: IFERROR AND formula?

    Sorry AL, I'll try and do better next time.

    Im guessing ISBLANK is the better option?
    Last edited by prudential; 04-25-2018 at 09:01 AM.

  9. #9
    Forum Contributor
    Join Date
    10-28-2014
    Location
    Sydney
    MS-Off Ver
    Professional 2010
    Posts
    151

    Re: IFERROR AND formula?

    If(and(a5="x",sumproduct(--($b$2:b4<>""))=0),"x1",

    if(and(a5="y",sumproduct(--($b$2:b4<>""))=0),"y1",

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Want to add IFERROR in my formula
    By HaroonSid in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-01-2017, 03:36 AM
  2. [SOLVED] Multiple IFERROR or IFERROR w/ If Statements
    By SanchoPanza1 in forum Excel General
    Replies: 4
    Last Post: 03-31-2016, 08:09 PM
  3. [SOLVED] IFERROR(MATCH & IFERROR(SMALL Help Needed
    By chad328 in forum Excel Formulas & Functions
    Replies: 14
    Last Post: 01-17-2016, 06:34 AM
  4. Iferror or other formula
    By sarahqputra in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 02-11-2015, 07:31 AM
  5. xlfn.IFERROR or IFERROR don't work in Excel 98-2003
    By dj_danu01 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-26-2013, 02:53 AM
  6. IFERROR Formula HELP PLEASE
    By jonnykhan in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 05-13-2013, 09:52 AM
  7. [SOLVED] #DIV/0 IFERROR formula
    By rlkerr in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 10-03-2012, 10:33 AM

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