代码如下:
var
fF : Textfile;
wF : string;
begin
webF:=‘E:/aa.txt’;
AssignFile(fF,wF);
Reset(fF);
closefile(fF);
end;在 Reset(fF)那行提示出错:Incompatible types: 'TObject' and 'Text'
百思不得其解,有人能告诉我是哪里出问题了吗?
PS:E:/aa.txt文件是存在的
var
fF : Textfile;
wF : string;
begin
webF:=‘E:/aa.txt’;
AssignFile(fF,wF);
Reset(fF);
closefile(fF);
end;在 Reset(fF)那行提示出错:Incompatible types: 'TObject' and 'Text'
百思不得其解,有人能告诉我是哪里出问题了吗?
PS:E:/aa.txt文件是存在的
fF : Textfile;
wF : string;
begin
wF:='E:\aa.txt';
AssignFile(fF,wF);
Reset(fF);
closefile(fF);
end;
fF : Textfile;
wF : string;
begin
wF:='E:\aa.txt;---------这里改动了一下(webF->wf,e:/aa.txt->e:\aa.txt)
AssignFile(fF,wF);
Reset(fF);
closefile(fF);
end;
fF : Textfile;
wF : string;
begin
wF:='E:\aa.txt';
AssignFile(fF,wF);
Reset(fF);
closefile(fF);
end;在 Reset(fF)那行提示出错:Incompatible types: 'TObject' and 'Text'感谢楼上三位,谢谢,能否再帮我看看这个是什么问题?
其实这段代码我在其他程序上执行是通过的,不知道为什么移植过另一个程序就不行了