traversing handlers aren't returning value
traversing handlers aren't returning value
- Subject: traversing handlers aren't returning value
- From: Eric Geoffroy <email@hidden>
- Date: Mon, 10 Jan 2005 16:32:04 -0800
I'm missing something obvious here.
The idea is to dig down into the file hierarchy and find certain file creators. If there's a hit on any one of them, it should stop and return the value. After three days of pulling my hair out I'm throwing in the towel.
Thanksabunch
Eric
set the foldr to (choose folder)
set ft to ""
-- Find text folders
tell application "Finder"
set text_folders_only to folders of the foldr whose name contains "text"
end tell
set ft to text_folders_only, ft)
say "result is" & ft
------ Handlers -----
--Process folders, no font folders. filters "fol" down
on foldrlist, ft)
repeat with thisFolder in foldrlist
say (name of thisFolder as string)
tell application "Finder"
set fils to files of thisFolder
set fols to (folders of thisFolder whose name does not contain "font")
end tell
if fils = {} then
say "no files in, " & (name of thisFolder as string)
else
fils)
end if
fols, ft)
return ft
end repeat
end processFolders
on filesToBeProcessed)
set creetor to ""
set ft to ""
repeat with thisFile in the filesToBeProcessed
say "processing " & name of thisFile as string
set creetor to file creator of (info for file (thisFile as string))
if creetor is "XPR3" then
set ft to "Quark 4.11, Mac"
say ft
return ft
else if creetor is "Fm70" then
set ft to "FrameMaker 7.0, Mac"
return ft
else if creetor contains "InDn" then
set ft to "InDesign CS, Mac"
return ft
end if
end repeat
end ProcessFiles
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden