I am still trying to get my head around this syntax.
I want to directly set a variable to have the value of an item from the “info for” function
I tried:
set var1 to display name of info for alias1
what am I doing wrong?
Thanks
I am still trying to get my head around this syntax.
I want to directly set a variable to have the value of an item from the “info for” function
I tried:
set var1 to display name of info for alias1
what am I doing wrong?
Thanks
It’s displayed name. And you don’t necessarily need to get info for the item.
Here’s the handliest little snippet I use:
tell app
set props to properties of
end tell
tell application "Finder" to set props to properties of (selection as alias)
Check out the wealth of information it returns, all of which can be used directly, without the Get Info part. And this kind of query is useful in many, many apps. (If you can’t get the selection directly in an app then you can try object IDs, stacking orders, whose clauses, etc.)
Have fun.
Jim Neumann
BLUEFROG