View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Don Guillett[_2_] Don Guillett[_2_] is offline
external usenet poster
 
Posts: 1,522
Default V-Lookup variation query

One way. copy col b to the end of col adelete col bsort col ause a macro
from the bottom up

sub nodups()
dim i as long
for i=cells(rows.count,1).end(xlup).row to 2 step -1
if cells(i-1,1)=cells(i,1) the rows(i).delete
next i
end sub
--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"njcr83" wrote in message
...
Hi,

I am having an issue with comparing columns of values.

Basically I have a table similar to the below except with a couple of
thousand lines.
Either the first column will have a value that doesn't match with the
second
column or vice versa so basically I need Excel (2002) to begin at the top
and
compare the values until it finds a mis-match, extract that value (perhaps
to
another sheet) and continue down the columns doing the same thing until
the
end.

46,898,748.00 46,898,800.00
2,365,412.00 2,365,412.00
15,465.00 15,465.00
4,864.00 4,864.00
41,564.00 54,156.00
48,642.00 41,564.00
1,564,968.00 48,642.00
4,589,846.00 1,564,968.00
5,852,852.00 4,589,846.00
6,458,456.00 5,852,852.00


At the moment I manually do this so, using the above example, I would go
down the list until the amount of 54,156.00 which I would cut and paste
into
a different sheet and then delete the cell with that value so the rest of
the
values on the right move up and match until the final amount on the left
of
6,458,456.00 which would also be removed as it also doesn't have a match.

With a couple of thousand items this is very time-consuming. I'm not sure
if
a v-lookup would help or perhaps a macro but any help would be greatly
appreciated.

Many thanks in advance

Niall