View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.programming
billbeecham[_13_] billbeecham[_13_] is offline
external usenet poster
 
Posts: 1
Default if cell value matches then copy another cell


Let me see if I can possibly clarify this. I sure hope this helps in
understanding my problem.

I'm going to just skip the other stuff and go for a (I hope) *simple*
compare and copy.


if sheet2 range(a:a) = sheet1 range(a:a) then copy sheet2 range(c:c) to
sheet1 range(c:c)

That's only how my very limited understanding of excel would be
expressed in a simplified manner.


I have two sheets. Sheet2 is like the master sheet, it contains
everything (and more) that sheet1 contains, only both sheets are in a
different (or random) order.

I need to compare (sheet to sheet) a1 to a1, if match then copy c1 to
c1

so basically, I want something like this:

compare sheet2 a1 to sheet1 a1,a2,a3,a4,a5,etc
if get match then copy sheet2 c1 to sheet1 c1

then move on to sheet2 a2 to sheet1 a1,a2,a3,etc
if get match then copy sheet2 c1 to sheet1 c1

until each cell in column A of sheet2 has been checked against each
cell in column A of sheet1, making sure to copy cell c as the matches
occur.

column A in both sheets are unique identifiers that are alpha-numeric.

Sheet1 needs to stay in the order it is in.


can anyone help me?


--
billbeecham
------------------------------------------------------------------------
billbeecham's Profile: http://www.excelforum.com/member.php...o&userid=16286
View this thread: http://www.excelforum.com/showthread...hreadid=488417