Autor Beitrag
toxicmaster
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 94



BeitragVerfasst: Sa 26.02.05 11:35 
hi,

also meine frage ist, ich habe nen shape und nen button und will während des button clicks, dass mein shape1 gefährbt wird.

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
procedure TForm1.Button1Click(Sender: TObject);
begin
  if button1.Click then
  Shape1.Brush.Color := clRed;
end;


gut soweit bin ich jetzt. aber bei dem then wird mir folgendes gesagt: "Ausdruck muss boolean sein."
Elite
Ehemaliges Mitglied
Erhaltene Danke: 1



BeitragVerfasst: Sa 26.02.05 11:51 
Also du willst, dass das Shape gefärbst ist, solange der Button nach unten gedrückt wird, richtig?
Dann müsstest du im OnMouseDown den Button färben und ihn bei OnMouseUp entfärben.
toxicmaster Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 94



BeitragVerfasst: Sa 26.02.05 11:57 
thx hat funktioniert