Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
compare data on 2 sheets
This is what am looking to do,
To compare data or two sheets So say sheet2 G4=exceltip and in sheet1 it then searches though G:G finds that cell G100 of shee 1 matches then it places X in cell H4 of sheet2 And Does this until Cell G# is empty Thanks Pau -- Message posted from http://www.ExcelForum.com |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
compare data on 2 sheets
Paul,
Sub TryNow() Dim myCell As Range Dim myFind As Range With Worksheets("Sheet2") For Each myCell In .Range(.Range("G4"), .Range("G4").End(xlDown)) Set myFind = Worksheets("Sheet1").Range("G:G").Find(myCell.Valu e) If Not myFind Is Nothing Then myCell(1, 2).Value = "X" Next myCell End With End Sub You could also do this with a formula in Column H.... HTH, Bernie MS Excel MVP "pauluk " wrote in message ... This is what am looking to do, To compare data or two sheets So say sheet2 G4=exceltip and in sheet1 it then searches though G:G finds that cell G100 of sheet 1 matches then it places X in cell H4 of sheet2 And Does this until Cell G# is empty Thanks Paul --- Message posted from http://www.ExcelForum.com/ |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
compare data on 2 sheets
A simple VLOOKUP should do the job. In cell H4 put formula :-
=IF(ISERROR(VLOOKUP(G4,Sheet1!G:G,1,FALSE)),"","X" ) and copy down -- Message posted from http://www.ExcelForum.com |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
compare data on 2 sheets
Brian,
Yes, your formula will work, but this is the programming group. So, perhaps, post code to put that formula into cell H4 and to copy it down to match column G. The OP may also not want formulas, so also include code to convert those formulas to values. Bernie MS Excel MVP "BrianB " wrote in message ... A simple VLOOKUP should do the job. In cell H4 put formula :- =IF(ISERROR(VLOOKUP(G4,Sheet1!G:G,1,FALSE)),"","X" ) and copy down. --- Message posted from http://www.ExcelForum.com/ |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
how can I compare two data sheets to find variances? | Excel Discussion (Misc queries) | |||
How can I compare data between two different sheets for changes? | Excel Worksheet Functions | |||
Compare two wk sheets with common data using copy paste macro | Excel Worksheet Functions | |||
how to compare two columns on two sheets and copy associated data from one sheet to the other? | Excel Worksheet Functions | |||
how to compare data in two different work sheets | Excel Worksheet Functions |