Hallo Alexander,
müsste dein Code nicht eher so aussehen (ungetestet)?
Delphi-Quellcode:
procedure TMainFrm.LViewCustomDrawSubItem(Sender: TCustomListView;
Item: TListItem; SubItem: Integer; State: TCustomDrawState;
var DefaultDraw: Boolean);
begin
with Sender.Canvas do begin
case SubItem of
1, 2, 8:
Font.Color := clGreen;
7:
begin
if Uppercase(Item.Caption) = 'JA'
then Font.Color := clGreen
else Font.Color := clRed;
end;
// else Font.Color := clSaved;
end;
end;
end;
Grüße vom marabu