N
noheart476
Unregistered / Unconfirmed
GUEST, unregistred user!
我的代码是这样的,但只能读一行
procedure TForm1.Button3Click(Sender: TObject);
var
//i : Integer;
F: TextFile;
S: string;
begin
AssignFile(F, 'D://123.txt');
Reset(F);
readln(F, S);
Edit1.Text := S;
stringgrid1.Cells[1,1]:=s;
CloseFile(F);
end;
procedure TForm1.Button3Click(Sender: TObject);
var
//i : Integer;
F: TextFile;
S: string;
begin
AssignFile(F, 'D://123.txt');
Reset(F);
readln(F, S);
Edit1.Text := S;
stringgrid1.Cells[1,1]:=s;
CloseFile(F);
end;