Z
zhengjp
Unregistered / Unconfirmed
GUEST, unregistred user!
如下:Readln(f,s);--为什么这里通不过编译,出错
var
F:file of shortstring;
s,t:shortstring;
begin
Assignfile(F,'c:/Loginame.dat');
if FileExists ('c:/Loginame.dat')=false then
begin
rewrite(F); {Loginame.ini 如果不存在,自动创建一个对应文件}
t:='adf';
write(f,t);
end
else
begin
Reset(F);
Readln(f,s);--为什么这里通不过编译,出错
showmessage(s);
end;
closefile(F);
end;
var
F:file of shortstring;
s,t:shortstring;
begin
Assignfile(F,'c:/Loginame.dat');
if FileExists ('c:/Loginame.dat')=false then
begin
rewrite(F); {Loginame.ini 如果不存在,自动创建一个对应文件}
t:='adf';
write(f,t);
end
else
begin
Reset(F);
Readln(f,s);--为什么这里通不过编译,出错
showmessage(s);
end;
closefile(F);
end;