+ Reply to Thread
Results 1 to 9 of 9

If THEN

  1. #1
    Registered User
    Join Date
    06-26-2018
    Location
    England
    MS-Off Ver
    2010
    Posts
    3

    If THEN

    Hi,

    I have spreadsheet where I have following problem:

    I need to fill is a column in a sheet with contacts. In this column I need to write the word “yes” or “no”. The data comes from different sheet within the same workbook. In this sheet the contacts are sorted by company. These companies have related contacts. These contacts are partners, Associates.n. The answer yes is correct if one of the related contacts is not in Frankfurt. If all related contacts have “Frankfurt” then the answer is “no”. So I have contacts with more than one associated firm contact. So I need a function to read out more than one row and give out a result from these.

    Any questions just let me know

  2. #2
    Valued Forum Contributor than_gold's Avatar
    Join Date
    10-17-2017
    Location
    Coimbatore India
    MS-Off Ver
    Office 365
    Posts
    646

    Re: If THEN

    you can use IF function comparing those cells.
    Regards,
    Thangavel D

    Appreciate the help? CLICK *

  3. #3
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    16.84 for Mac MS 365
    Posts
    8,499

    Re: If THEN

    possibly a countif formula, but to get a better more accurate response posting a sample sheet with no sensitive / private information, representative data and expected results will get you a better answer. Click on the go advanced button below this box, then manage attachments and follow the prompts to upload a sample sheet.
    Make contributors happy, click on the "* Add Reputation" as a way to say thank you.
    Sam Capricci

  4. #4
    Registered User
    Join Date
    06-26-2018
    Location
    England
    MS-Off Ver
    2010
    Posts
    3

    Re: If THEN

    Hi,

    I have attached an example. The column J has to filled with "yes" or "no". The criteria is column I. If the company has one or more related contacts that are not in Frankfurt the answer is "yes" otherwise "no"
    Attached Files Attached Files

  5. #5
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    16.84 for Mac MS 365
    Posts
    8,499

    Re: If THEN

    You really didn't put in your expected results as I mentioned in post #3. So I'm guessing but this may work for you and I am basing it on columns G and I because you mentioned "related contacts" which appears to be column G and you mentioned column I.

    =IF(COUNTIFS($G$2:$G$20,G2,$I$2:$I$20,"<>&Frankfurt")<>COUNTIFS($G$2:$G$20,G2,$I$2:$I$20,"Frankfurt"),"yes","no")

    adjust the ranges to suit.
    More clarity would be helpful to better refine a formula.

  6. #6
    Registered User
    Join Date
    06-26-2018
    Location
    England
    MS-Off Ver
    2010
    Posts
    3

    Re: If THEN

    Hi,

    thanks for your help. The expected results are "yes" if one of the related contacts is not in Frankfurt. Otherwise the expected result is "no"

  7. #7
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,938

    Re: If THEN

    Hi, welcome to the forum

    Please take a moment to read the forum rules and then amend your thread title to something descriptive of your problem - not what you think the answer might be. (think google search terms?). Once you have done this please send me a PM and I will remove this request. (Also, include a link to your thread - copy from the address bar)

    Many members search our previous posts, and thread titles play a big part of the search. I doubt anybody would do a search based on your title?

    To change a Title on your post, click EDIT POST then Go Advanced and change your title, if 2 days have passed ask a moderator to do it for you.

    (note: this change is not optional )
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  8. #8
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    16.84 for Mac MS 365
    Posts
    8,499

    Re: If THEN

    You're welcome. Then, based on your last post I assume the issue is resolved because that formula appears to work if one of the locations is Frankfurt and if it isn't.
    Don't forget to mark the post as solved using the thread tools dropdown at the top of the post.

    If the issue isn't resolved then more clarity on which columns to base the formula on is what is needed. As I noted I'm guessing it is based on columns G and I.
    AND more examples WITH expected results would help.

    EDIT: Hi Ford, I was typing the post while you posted that note.

  9. #9
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,938

    Re: If THEN

    Quote Originally Posted by Sambo kid View Post
    ...EDIT: Hi Ford, I was typing the post while you posted that note.
    Not a problem - timing issue, it happens

+ 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