tell application "Mail" set theId to id of item 1 of (selection as list) set theUrl to "file://" & (do shell script "mdfind -onlyin ~/Library/Mail \"kMDItemFSName = '" & theId & ".emlx'\"") tell application "iCal" activate -- iCal doesn't have a selected event property, so this is the best we can do for now set the clipboard to theUrl beep end tell end tell