2013-11-28 4 views
1

나는이 내용의 폴더 (파일 및 폴더)를 나열 다음 스크립트AppleScript로 폴더의 파일 이름을 얻을

set the_files to (list folder (choose folder) without invisibles) 

예를 들어, 폴더 루트 파일 text1.txt 및 폴더 subroot2 및 subroot3

있다

하지만 폴더 루트의 파일 이름 (text1.txt 만)을 어떻게 얻을 수 있습니까 (서브 루트 2 및 서브 루트 3 제외)? 감사합니다.

답변

1
tell application "Finder" 
    files of folder (choose folder) -- Finder file objects 
    name of files of folder (choose folder) -- names of files 
end tell 
관련 문제