+ Reply to Thread
Results 1 to 6 of 6

Formula not showing correctly

  1. #1
    Registered User
    Join Date
    05-30-2012
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    17

    Formula not showing correctly

    When i run a formula(=IF(COUNTIF(Sheet2!A:A,Sheet1!B1)=1,IF(Sheet1!C1=1,"NEEDS 2B Removed","ACTIVE"),"")) it isnt showing correctly because the value it is looking up (Sheet1!B1) is in the separate spreadsheet9Sheet1!C) 2+ times. Is there any way around this?

    I have attached a sample of what the issue is.

    Thanks,
    Attached Files Attached Files

  2. #2
    Forum Contributor
    Join Date
    09-27-2012
    Location
    London, England
    MS-Off Ver
    2003, 2010
    Posts
    344

    Re: Formula not showing correctly

    Quote Originally Posted by BROOF View Post
    ... it isnt showing correctly because the value it is looking up (Sheet1!B1) is in the separate spreadsheet9Sheet1!C) 2+ times.
    Not sure if I understand this part. Try the below in Sheet 1:

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Seems to work?
    If solved kindly remember to mark Thread as solved.
    Click the small star icon at the bottom left of my post if this was useful.

  3. #3
    Registered User
    Join Date
    05-30-2012
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    17

    Re: Formula not showing correctly

    sorry should explain better, the value in the cell B1 is listed twice in A:A and from what i can gather than is making the formula show incorrectly.

    In the attached file A1 should show "NEEDS 2B Removed" instead of showing Blank, which means that the formula is calculating FALSE instead of True.

    Does this help?

  4. #4
    Forum Expert Fotis1991's Avatar
    Join Date
    10-11-2011
    Location
    Athens(The homeland of the Democracy!). Greece
    MS-Off Ver
    Excel 1997!&2003 & 2007&2010
    Posts
    13,744

    Re: Formula not showing correctly

    Your formula is this.

    =IF(COUNTIF(Sheet2!A:A;Sheet1!B1)=1;IF(Sheet1!C1=1;"NEEDS 2B Removed";"ACTIVE");"")

    In sheet2!A:A, number 1, exists 2 tImes. A1 &A13. so correctly does not show "NEEDS 2B Removed" as result.
    Regards

    Fotis.

    -This is my Greek whisper to Europe.

    --Remember, saying thanks only takes a second or two. Click the little star * below, to give some Rep if you think an answer deserves it.

    Advanced Excel Techniques: http://excelxor.com/

    --KISS(Keep it simple Stupid)

    --Bring them back.

    ---See about Acropolis of Athens.

    --Visit Greece.

  5. #5
    Registered User
    Join Date
    05-30-2012
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    17

    Re: Formula not showing correctly

    is there special characters or additional info i would need to add to make the formula function so if Sheet1!B1 is found in Sheet2!A:A no matter how many times then the second hlf of the formula would work(IF(Sheet1!C1=1;"NEEDS 2B Removed";"ACTIVE");""))

    Does this make sense?

  6. #6
    Forum Contributor
    Join Date
    09-24-2012
    Location
    York, England
    MS-Off Ver
    Excel 2003/07/10
    Posts
    165

    Re: Formula not showing correctly

    Hello Broof
    The problem is that COUNTIF must return 1 for the second IF to become operative. A1 is blank because COUNTIF returns 2
    Try this in Sheet1("A1"):

    =IF(COUNTIF(Sheet2!$A:$A,B1)>0, IF(C1=1, "NEEDS 2B Removed", "ACTIVE"),"")

    HTH

+ 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