Never been to TextSnippets before?

Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world (or not, you can keep them private!)

Reliably change Adium Status (See related posts)

This applescript snippet will change the away/available status of your Adium accounts. This is the only applescript I have found that has worked.


-- set to available
do_menu("Adium", "Status", "Available")

-- set to away
do_menu("Adium", "Status", "Away")


on do_menu(app_name, menu_name, menu_item)
        try
                -- bring the target application to the front
                tell application app_name
                        activate
                end tell
                tell application "System Events"
                        tell process app_name
                                tell menu bar 1
                                        tell menu bar item menu_name
                                                tell menu menu_name
                                                        click menu item menu_item
                                                end tell
                                        end tell
                                end tell
                        end tell
                end tell
                return true
        on error error_message
                return false
        end try
end do_menu

You need to create an account or log in to post comments to this site.


Related Posts