我已经读过,Delphi应该是为Delphi 9中的每个循环获得的。这个功能是否已经成为这个语言?我的Delphi 2009 IDE似乎没有识别每个语法。这是我的代码:
procedure ProcessDirectory(p_Directory,p_Output : string); var files : TStringList; filePath : string; begin files := GetSubfiles(p_Directory); try for (filePath in files.Strings) do begin // do something end; finally files.Free; end; end;
解决方法
procedure ProcessDirectory(p_Directory,p_Output : string); var files : TStringList; filePath : string; begin files := GetSubfiles(p_Directory); try for filePath in files do begin // do something end; finally files.Free; end; end;
原文地址:https://www.jb51.cc/delphi/103258.html
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。