View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.misc
Emece Emece is offline
external usenet poster
 
Posts: 82
Default Macro to find duplicates

Perhaps I didn't express myself correctly. I have several values in column B,
and values that are duplicated not necessarily are in adjacent rows. So, I
need to check the entire column and find duplicated values. Also, if the
value is duplicated, after doing 345+345, I need to delete one of both value.
Hope now it is clear enough.

Thanks again

"Sheeloo" wrote:

If you want to multiply only those values which are duplicate (a 2 in Col A)
then use this in C1 and copy down
=IF(A1=2,B1*A1,"")

If you want to multiple all values then simply use
=B1*A1

If you want to multiply all values greater than 1 then use
=IF(A11,B1*A1,"")

What is your ultimate purpose in doing this?

"Emece" wrote:

Hi, I have a worksheet that has the following structure

A B
1 2 345
2 1 345
3 1 512

In column B there are values, and in column A there is a number that
indicates if the value in column B is repeated. In case it is repeated, I
want a macro that display in column C the result of multiplying that value
*2. Following the example I just wrote, I would need the value 690 displayed
in column C.

Hope it is clear enough

Thanks in advance

Regards,
Emece.-