Closed Thread
Results 1 to 8 of 8

Cancel

  1. #1
    Forum Contributor
    Join Date
    02-21-2013
    Location
    newcastle
    MS-Off Ver
    2011
    Posts
    111

    Cancel

    hi guys

    hi guys

    i am looking for a marco or formula for this please: Basically as you can see above i have 2 sheets, i need a marco that will place the result in E1,2,3 etc on Sheet 2. The marco/formula needs to look across Sheet1 Columns C and D, find exact match in the same columns on sheet 2, then give a value in sheet 2 cell E.


    Sheet 1

    C1 - Scots
    C2 - Scots

    D1 - EH13
    D2 -EH12


    Sheet 2

    C1 - Scots
    C2 - Scots

    D1 - EH13 (gives a 0 in E1 sheet 2 as its found a match)
    D2 - EH1 (gives a 1 in E2 sheet 2 as its has not found a match)



    as ever thank you guys in advance for any help you can help
    Last edited by mickgibbons1; 04-28-2017 at 04:49 AM.

  2. #2
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,435

    Re: matching two columns against 2 other columns in a different spreadsheet then add a val

    Try:

    =1-AND(C1=Sheet1!C1,C2=Sheet1!C2)
    Quang PT

  3. #3
    Forum Contributor
    Join Date
    02-21-2013
    Location
    newcastle
    MS-Off Ver
    2011
    Posts
    111

    Re: matching two columns against 2 other columns in a different spreadsheet then add a val

    hi bebo

    sorry mate, i dont need it to match the cells but to search the cells, find that both match and then give a 0 or a 1 if they do not match.

  4. #4
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: Cancel

    So in EH13, you want
    =IF('sheet 1'!D1 = 'sheet 2'D1, 0,1)
    and in EH1, same thing
    =IF('sheet 1'!D2 = 'sheet 2'D2, 0,1)
    Is that what you are looking to do?
    ChemistB
    My 2?

    substitute commas with semi-colons if your region settings requires
    Don't forget to mark threads as "Solved" (Edit First post>Advanced>Change Prefix)
    If I helped, Don't forget to add to my reputation (click on the little star at bottom of this post)

    Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble

  5. #5
    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,926

    Re: Cancel

    Why did you rename this thread to Cancel?
    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

  6. #6
    Forum Contributor
    Join Date
    02-21-2013
    Location
    newcastle
    MS-Off Ver
    2011
    Posts
    111

    Re: Cancel

    because i wanted to delete it as i have the same thread posted twice

  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,926

    Re: Cancel

    OK I will close this 1, can you give me the link to the other 1 please?

  8. #8
    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,926

    Re: Cancel

    OK I think it was this 1, let me know if Im wrongh?
    https://www.excelforum.com/excel-for...s-a-value.html

Closed Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. matching 2 columns to 2 columns to display price from 3rd col
    By razer1 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 12-27-2015, 03:41 PM
  2. [SOLVED] Sumif two columns matching another two columns
    By kl99ny in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 12-11-2013, 02:08 PM
  3. [SOLVED] Align 3 columns with 2 columns of matching data
    By loritee in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-23-2013, 10:36 AM
  4. Align 3 columns with 2 columns of matching data
    By bearnbillie in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-04-2012, 08:33 AM
  5. Replies: 3
    Last Post: 06-09-2011, 05:58 AM
  6. sort columns based on matching 1st & 2nd columns
    By repke in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 02-13-2011, 01:37 PM
  7. compare columns and count number of matching columns
    By san000 in forum Excel General
    Replies: 1
    Last Post: 07-15-2009, 10:31 PM

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