<pre>on mouseUp -- sample  toComputer  put panFolder() & "Stacks:" into stacksFolder  put recursiveGetFiles(stacksFolder) into content  put filterResults(content) into content  writeFile content,"List of Stacks"  beep 2end mouseUpfunction getFilesRecursively rootFolder  if there is not a folder rootFolder then die "No such folder"  put getFoldersRecursively(rootFolder) into folders  put filterResults(folders) into folders  if folders is not empty then return recursiveListFiles(folders)  put listFileNames(rootFolder) into foundFiles  if foundFiles is not empty then    repeat with x = 1 to the number of lines of foundFiles      put rootFolder & (line x of foundFiles) into line x of foundFiles    end repeat  end if  return foundFilesend getFilesRecursivelyfunction recursiveListFiles folders  repeat with x = 1 to the number of lines of folders    put line x of folders into currentFolder    put listFileNames(currentFolder) & return after newFiles    if newFiles is not empty then      repeat with y = 1 to the number of lines of newFiles        if line y of newFiles is empty then next repeat        put currentFolder & (line y of newFiles) & return after foundFiles      end repeat      put empty into newFiles    end if  end repeat  return foundFilesend recursiveListFiles--------------------------------- SUPPORTING CAST ------------------------------------------------------------- Handlers located elsewhere ---------------------------on die dyingMsg  if dyingMsg is not empty then answer dyingMsg  exit to HyperCardend diefunction filterResults paths  repeat with x = the number of lines of paths down to 1    if line x of paths is empty then delete line x of paths  end repeat  sort lines of paths  repeat with x = the number of lines of paths down to 1    if line x of paths is line (x-1) of paths then delete line x of paths  end repeat  return pathsend filterResultsfunction getFoldersRecursively rootFolder  ---  put rootFolder into basePath  put rootFolder & return into cat  ---  put listFolderNames(rootFolder) into mainCat  if mainCat is empty then return empty  repeat with x = 1 to the number of lines of mainCat    put basePath & (line x of mainCat) & ":" & return after cat  end repeat  ---  repeat with x = 2 to the number of lines of cat    put getFoldersRecursively(line x of cat) into newFolders    if newFolders is not empty then put newFolders & return after cat  end repeat  ---  return cat  ---end getFoldersRecursively</pre>