I have an applescript to initiate my work environment, but have a small quibble with it. I want the script to launch several programs, and then hide them, once they started. The code looks like this currently:
tell application "Firefox" to activate delay 0.5 tell application "Finder" set visible of process "Firefox" to false end tell
Obviously, delay 0.5 is just a placeholder, ideally I would want to hide the program as soon as it finished loading. Unfortunately, my load times vary a lot (from 0.2 - 5s) Is there something like a callback or a function to monitor the events of applications?