Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the '10.3: Record Finder actions in Script Editor' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
10.3: Record Finder actions in Script Editor
Authored by: Graff on Oct 30, '03 05:16:02PM
any one know how to get the icon position data if you know the file name?

I know that you can get the positions of the icons with the following short example script:

tell application "Finder"
	set desktopList to every item in the desktop
	repeat with theItem in the desktopList
		set thePosition to the position of theItem

-- Do something here with thePosition

	end repeat
end tell

The key is that you have to use the reference desktop. The path ~/Desktop/ is something completely different and it doesn't contain the position of the icons.



[ Reply to This | # ]
10.3: Record Finder actions in Script Editor
Authored by: nvdingo on Nov 01, '03 08:45:27PM

thank you!!!
i was grappling with that.
i don't get the object model enough to figure it out.

i opened the finder dict and tried to figure out what to do.
about 2 hours of fiddling, and i figured out how to do a lot, but not move the icons.

i had the wrong set of classes referencing the icons.

thanks graff!



[ Reply to This | # ]