Hi,
Thanks for taking the time to provide this information to me. I know it's been awhile, but I just recently got the time to try this. I think I'm close, but still running into some errors. I'm an AppleScript novice, so bear with me, but here's what I got...
When I'm attempting to run the script, I'm getting the message:
Syntax Error
Expected end of line, etc. but found “"”.
When I click OK, it highlights the first quote after before the sound name ("Sosumi").
Any ideas? I've posted my syntax below. Thanks.
----------------------------------
using terms from application "Messages"
on message received theMessage from theBuddy for theChat
if name of theBuddy is myBuddysName then
set notificationMessage to myBuddysName & " sent a message"
display notification notificationMessage with sound name "Sosumi"
delay 1
end if
end message received
# The following are unused but need to be defined to avoid an error
on received text invitation theText from theBuddy for theChat
end received text invitation
on received audio invitation theText from theBuddy for theChat
end received audio invitation
on received video invitation theText from theBuddy for theChat
end received video invitation
on received remote screen sharing invitation from theBuddy for theChat
end received remote screen sharing invitation
on received local screen sharing invitation from theBuddy for theChat
end received local screen sharing invitation
on received file transfer invitation theFileTransfer
end received file transfer invitation
on buddy authorization requested theRequest
end buddy authorization requested
on message sent theMessage for theChat
end message sent
on message received theMessage from theBuddy for theChat
end message received
on chat room message received theMessage from theBuddy for theChat
end chat room message received
on active chat message received theMessage
end active chat message received
on addressed chat room message received theMessage from theBuddy for theChat
end addressed chat room message received
on addressed message received theMessage from theBuddy for theChat
end addressed message received
on av chat started
end av chat started
on av chat ended
end av chat ended
on login finished for theService
end login finished
on logout finished for theService
end logout finished
on buddy became unavailable theBuddy
end buddy became unavailable
on completed file transfer
end completed file transfer
end using terms from