procedure TForm1.FindAll(const Path: String);
var
  sr:TSearchRec;
  fr:Integer;
begin
fr:=FindFirst(Path,faAnyFile,sr);
while fr=0 do
  begin
  if (sr.Attr=faDirectory)and(sr.Name<>'.')and(sr.Name<>'..') then
    FindAll(sr.Name)  
  else
    begin
     showmessage(sr.name);
    end;
  FindNext(sr);
  end;
FindClose(sr);
end;我是从网上找到的这个函数,可是调用时总是不停时showmessage,一直停不下来,这是为什么呢?万分感谢!