Registriert seit: 16. Jan 2004
Ort: Bendorf
5.219 Beiträge
Delphi 10.2 Tokyo Professional
|
Re: ListBox & Edit
6. Sep 2006, 17:38
Delphi-Quellcode:
procedure TForm1.Button1Click(Sender:TObject);
var i: Integer;
begin
for i:= 0 to ListBox1.Items.Count-1 do
begin
(FindComponent('Edit' + IntToStr(i+1) as TEdit).Text := ListBox1.Items[i];
end;
end;
So müsste es gehn. Vorraussetzung: Es muss so viele Edits geben wie es Einträge in der ListBox gibt!
Gruß
Neutral General
Michael "Programmers talk about software development on weekends, vacations, and over meals not because they lack imagination,
but because their imagination reveals worlds that others cannot see."
|