|
[广告] Excel易用宝 - 提升Excel的操作效率 · Excel / WPS表格插件 ★ 免费下载 ★ ★ 使用帮助★
Sub 按钮1_Click()
Set d = CreateObject("scripting.dictionary")
With CreateObject("vbscript.regexp")
.Pattern = "\d+"
.Global = True
For j = 8 To 4 Step -1
For i = 8 To 4 Step -2
If .test(Cells(j, i)) Then
d.RemoveAll
For Each m In .Execute(Cells(j, i))
d(Val(m) + 1) = ""
Next m
Set Rng = Cells(j - 1, i - 2)
If .test(Rng) Then
For Each m In .Execute(Rng)
If d.exists(Val(m)) Then
Rng.Characters(m.firstindex + 1, m.Length).Font.ColorIndex = 3
End If
Next m
End If
End If
Next i
Next j
End With
End Sub
|
评分
-
1
查看全部评分
-
|