Sub changeColor()
For i = 1 To Range("B65536").End(xlUp).Row
temp = Cells(1, 3)
Cells(i, 2).Select
a = InStr(1, Cells(i, 2), temp)
ActiveCell.Font.ColorIndex = 1
If a > 0 Then
ActiveCell.Characters(Start:=a, Length:=2).Font.ColorIndex = 7
End If
Next
End Sub
Excel 改变指定字符颜色
最新推荐文章于 2020-05-06 15:48:53 发布