Page 1 of 1

AppleScript : Notification of new messages.

Posted: Wed Mar 15, 2006 2:39 pm
by mac4ever
Is there a way to launch an applescript procedure when a new message is sent to an account, in order to get the content of the message and select an option to launch ?

My goal is to launch apple scripts using addium as a distant script launcher.

I'd like to find code example of such functionnalities, but I can't find any.

Thanks a lot.

Cyril.

Posted: Wed Mar 15, 2006 3:22 pm
by yelly
in the events pref-pane, you can make any event (including receiving messages) run an applescript.

Posted: Thu Mar 16, 2006 8:51 am
by mac4ever
My problem is that I'd like the applescript to know the message and the account it was sent by, and I don't think I can make it this way.


I remember having scripted Ircle before, and there is a method you can use in an applescript (loaded by Ircle), that is called every time a message was recieved, with global variables (last message, etc...).

What i'd like would be code examples from existing script using this functionnality (my last programming was 10 mounth ago...)

Posted: Thu Mar 16, 2006 2:52 pm
by evands
Such functionality does not exist in Adium. If you're interested, we'd be happy to accept a clean patch implementing this capability. Colloquy (colloquy.info) has an applescript plugin system which could serve as an example for an implementation.