Dim r As Range
Dim i As Integer
For Each r In ActiveSheet.UsedRange
i = 0
Do While InStr(i + 1, r.Value, "测试场景") > 0
i = InStr(i + 1, r.Value, "测试场景")
r.Select
ActiveCell.Characters(Start:=i, Length:=4).Font.Bold = True
Loop
Next
End Sub
Dim i As Integer
For Each r In ActiveSheet.UsedRange
i = 0
Do While InStr(i + 1, r.Value, "测试场景") > 0
i = InStr(i + 1, r.Value, "测试场景")
r.Select
ActiveCell.Characters(Start:=i, Length:=4).Font.Bold = True
Loop
Next
End Sub