Posted: Mon Aug 27, 2007 4:34 am
I've looked at http://growl.info/documentation/ and http://trac.growl.info/trac/ticket/324 ... not finding what you're describing.
Code: Select all
try -- to get a reference to growl
tell application "Finder" to set growlHelperApplication to name of application file id "com.Growl.GrowlHelperApp" as string
--tell application "System Events" to set GrowlExists to exists application process ("GrowlHelperApp" as string)
set GrowlExists to true
on error -- Growl is not installed
set GrowlExists to false
end try
using terms from application "GrowlHelperApp"
tell application growlHelperApplication to notify title |title| description msg application name _appName with name (_scriptName & " " & notification)
end using terms from
Where the h*** do we add the code to?The_Tick wrote:Hey nanovivid. When you guys get this figured out, can you add this and http://trac.growl.info/trac/ticket/324 to the applescript docs?
Code: Select all
tell application "System Events" to set GrowlRunning to exists application process "GrowlHelperApp"
set Message to "So this message appears in Growl"
set altMsg to "GrowlHelperApp is not running"
Notify(Message, altMsg, GrowlRunning)
on Notify(msg, altMsg, Growler)
if Growler then
tell application "GrowlHelperApp"
register as application "NoteTester.scpt" all notifications {"Note"} default notifications {"Note"} icon of application "Script Editor"
notify with name "Note" title "GrowlHelperApp is Running" description msg application name "NoteTester.scpt"
end tell
else
display dialog altMsg
end if
end Notify