Setting file type and creator in a droplet

I am updating one of my scripts.

Basically it will just set the file type and creator type of an item dropped onto it.

I’m having a problem with:


on open (droppedItems)
Tell application "finder"
set creator type of (item 1 of droppeditems) to "1234"
end tell
end open

basically the script will not compile, it just does not like 'creator type'

I have looked in the finder dictionary and 'creator type' is a property of file.

Any ideas why this will not work?

Is it possible to set the file type and creator type of an item via the terminal? in other words could I use a 'do shell script' command to do this instead of using the finder?

Doesn’t this work? :!: :!:

on open droppedItems
	tell application "Finder"
		set creator type of (item 1 of droppedItems) to "1234"
	end tell
end open

If you installed Developer Tools, type this in a Terminal window:

/Developer/Tools/SetFile

Bingo, SetFile’s the chap.

Have got a script performing a ‘do shell script’ to run setfile