I know AppleScript is slowly dying, and GUI scripting is, like, the worst part of automation with AS, but this script is a godsend even if you're using JSX. It takes any running app and creates a hierarchical list of every menu item in it, making it easy to [script choosing them](http://www.macosxautomation.com/applescript/uiscripting/index.html).