add an alias to the sidebar of the finder window through applescript.

Hello all

I have a script that mounts several network shares and then creates an alias to a specific folder within each mount.
I was wondering if I can script it to put a copy of the alias in the sidebar of the finder window so that when people go to save files from a program like Garageband they see the alias for the folder in the sidebar instead of having to find it from the desktop or the mounted drive.

Does this make sense?

Thanks in advance,

DT

Model: powerbook g4
AppleScript: 2.1.1 (81)
Browser: Safari 523.12.9
Operating System: Mac OS X (10.4)

Hi DT

I’m not sure of anyway of adding items to the sidebar without GUI scripting
so this is my attempt.

when the file is added to the side bar it becomes an alias anyway.
but i guess if you have created your alias firstly then it should still work!!

tell application "Finder"
	set t to choose file
	open container of t
	set selection to t
	tell application "System Events"
		tell process "Finder"
			set frontmost to true
			delay 1
			keystroke "t" using command down
		end tell
	end tell
end tell