function TData1.DeleteDirectory(const Source:String): boolean;var fo: TSHFILEOPSTRUCT;begin FillChar(fo, SizeOf(fo), 0); with fo do begin Wnd := 0; wFunc := FO_DELETE; pFrom := PChar(source+#0); pTo := PChar(source+#0); fFlags := FOF_NOCONFIRMATION+FOF_NOCONFIRMMKDIR ; end; Result := (SHFileOperation(fo) = 0);end;这个