Autor Beitrag
theluckyghost
Hält's aus hier
Beiträge: 3



BeitragVerfasst: Mo 24.02.03 16:03 
Hi,
ich sitz hier gerade in der Schule im Delphikurs und wir haben folgendes Problem. Wir wollen mir einer Schleife Zahlen in verschiedene Textboxen reinschreiben. Leider müssen wir dabei für jede neue Textbox eine neue Zeile anfangen:
ausblenden Quelltext
1:
2:
3:
4:
5:
Edit1.Text:=inttostr(a[1]);
Edit2.Text:=inttostr(a[2]);
Edit3.Text:=inttostr(a[3]);
Edit4.Text:=inttostr(a[4]);
Edit5.Text:=inttostr(a[5]);

Gibt es eine Möglichkeit Diese Textboxen mit einer Art index zu durchlaufen?

Danke
Benjamin
Ex0rzist
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 550

Win XP Prof.
Mandrake 10.0

D6
BeitragVerfasst: Mo 24.02.03 16:08 
Versuche mal das hier:

ausblenden Quelltext
1:
2:
For i := 1 to x do
 TEdit(FindComponent('Edit'+IntToStr(i))).Text := IntToStr(a[i]);

_________________
If accidentally read, induce vomitting.