hi,
du brauchst den ganzen 'if..then..else-kram' nicht
probiere es mal so:
Delphi-Quellcode:
procedure TForm1.SynEdit1StatusChange(Sender: TObject;
Changes: TSynStatusChanges);
begin
Button2.Enabled := SynEdit1.Modified;
Button3.Enabled := SynEdit1.CanRedo;
Button4.Enabled := SynEdit1.CanUndo
end;
procedure TForm1.Button1Click(Sender: TObject);
begin
SynEdit1.Modified := False
end;
procedure TForm1.Button3Click(Sender: TObject);
begin
Synedit1.Redo
end;
procedure TForm1.Button4Click(Sender: TObject);
begin
SynEdit1.Undo
end;