oi oi oi...mit records hab ich mich noch gar nicht beschäftigt...hab aber auch keine lust jetzt mein ganzes programm über den haufen zu werfen

...ich poste mal hier den quelltext rein, vielleicht könnt ihr mir ja so besser helfen:
Delphi-Quellcode:
procedure TForm2.naufgabeClick(Sender: TObject);
var i,art:integer;
begin
listbox1.Items.LoadFromFile('vokabel.txt');
case radiogroup1.itemindex of
0: art:=1;
1: art:=2;
else art:=random(2)+1;
end;
case art of
1:begin
i:=random(listbox1.Items.Count);
panel1.Caption:=listbox1.Items.names[i];
loesung:=listbox1.Items.ValueFromIndex[i];
end;
2:begin
i:=random(listbox1.Items.Count);
panel1.Caption:=listbox1.Items.ValueFromIndex[i];
loesung:=listbox1.Items.names[i];
end;
end;
eingabe.text:='';
bewertung.caption:='';
eingabe.setfocus;
end;
procedure TForm2.eingabeKeyPress(Sender: TObject; var Key: Char);
begin
if key=#13 then
begin
if eingabe.text=loesung then bewertung.caption:='richtig'
else bewertung.caption:='falsch';
naufgabe.setfocus;
end;
end;
procedure TForm2.FormCreate(Sender: TObject);
begin
randomize;
end;
end.