发布网友
共1个回答
热心网友
Sub 宏1()
Set db = CreateObject("Scripting.Dictionary")
for i = 2 to ActiveSheet.UsedRange.Rows.Count
If i<=14 Then
db(Trim(Cells(i,3)) = True
Else
If db(Trim(Cells(i,3)) Then
MsgBox "第"& i &"行数据【"& Cells(i,3) &"】重复!"
Else
With Range(Cells(i,1), Cells(i,6)).Borders
.LineStyle = xlContinuous
.Weight = xlMedium
End With
End If
End If
next i
End Sub