Sub
Gruppe1()
Dim
MeinBereich
As
Range
Dim
Zelle
As
Object
On
Error
GoTo
Canceled
Set
MeinBereich = Application.InputBox(Prompt:=
"Bereich wählen"
, Title:=
"Bereich wählen"
, Type:=8)
For
Each
Zelle
In
MeinBereich
Zelle.Characters(InStr(4, Zelle.Value,
"H350"
), 4).Font.ColorIndex = 3
Zelle.Characters(InStr(4, Zelle.Value,
"H340"
), 4).Font.ColorIndex = 3
Zelle.Characters(InStr(4, Zelle.Value,
"H410"
), 4).Font.ColorIndex = 3
Zelle.Characters(InStr(4, Zelle.Value,
"H300"
), 4).Font.ColorIndex = 5
Zelle.Characters(InStr(4, Zelle.Value,
"H301"
), 4).Font.ColorIndex = 5
Zelle.Characters(InStr(4, Zelle.Value,
"H310"
), 4).Font.ColorIndex = 5
Next
Exit
Sub
Canceled:
End
Sub
Beim Beispiel