Re: Help w/ creator changer script
Re: Help w/ creator changer script
- Subject: Re: Help w/ creator changer script
- From: Michelle Steiner <email@hidden>
- Date: Fri, 14 Dec 2001 19:27:52 -0700
On 12/14/01 3:15 PM, Harold Bert Martin <email@hidden> wrote:
>
I wrote a drag-n-drop script for changing the creator types of files.
>
When a file (as opposed to folder) is dropped on it, it gives me errors
>
about either memory(stack overflow) or string(alias) types.
Here's a script I wrote to do this. It doesn't handle folders, and I
never bothered to trap it for folders being dropped on it. It's for my
own use, so I know its limitations.
Hope it may be of any help.
--Michelle
property creatortype : "GKON"
on run
display dialog ,
"Enter the creator type." default answer creatortype buttons {"Cancel",
"GKON", "Text Field"} default button 3
if button returned of the result is "GKON" then
set the creatortype to "GKON"
else
set the creatortype to text returned of the result
end if
end run
on open (theFiles)
tell application "Finder"
repeat with theFile in theFiles
set the creator type of theFile to the creatortype
end repeat
end tell
end open
----------------------------------------------------------------------
| Michelle Steiner | We're not human beings having a spiritual |
| | experience. We're spiritual beings |
| email@hidden | having a human experience. |
----------------------------------------------------------------------