Skip to content

Instantly share code, notes, and snippets.

@AshCoolman
Created May 25, 2016 18:00
Show Gist options
  • Save AshCoolman/0c453c695aba9cb8b6821d34935a7e0d to your computer and use it in GitHub Desktop.
Save AshCoolman/0c453c695aba9cb8b6821d34935a7e0d to your computer and use it in GitHub Desktop.
UI Browser.applescript
-- http://hints.macworld.com/article.php?story=20111208191312748
set appname to "1Password" -------------------------- Set this to the App you want to look at
set winstuff to "defaultval"
set menustuff to "defaultval"
tell application appname
activate
end tell
tell application "System Events"
tell process appname
set winstuff to entire contents of front window
set menustuff to entire contents of menu bar 1
end tell
end tell
--return winstuff & "rrrr" & menustuff -- comment this out to get just winstuff
return winstuff -- comment this out too to get just menustuff
--return menustuff
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment