Remove duplicate enries with blank fields

M

martinvanduijn

I need to create a key word index for past issues of a magazine. Th
index will be published on the publisher's website. Key words, title
and issues are collected in an Excel file, and are alphabeticall
sorted. One keyword can have multiple references to articles, but fo
eastethic reasons I want to remove duplicate keywords while off cours
maintaining the title and issue info. The result should look like this


http://www.belastingzaken.nl/trefwoordenregister/P.htm (it's Dutch)

I have deleted duplicate key words manually, but since I need to updat
this index each month that's just too much work, so I'm looking for
way or a product that can do that for me.

Who can advise me
 
F

Frank Kabel

Hi
try the following macro

sub foo()
Dim row_index
Dim Lastrow
LastRow = ActiveSheet.Cells(Rows.Count, "A").End(xlUp).row
for row_index = LastRow-1 to 1 step -1
if cells(row_index,"A").value=cells(row_index+1,"A").value then
cells(row_index+1,"A").clearcontents
end if
next
end sub
 
Top