Trying to quit/launch Parallels using Apple Script

Discussion in 'General Questions' started by Ahwman, Jun 17, 2017.

  1. Ahwman

    Ahwman Junior Member

    Messages:
    15
    Hello,

    I'm running a Parallels Desktop virtual machine (Windows 7) on my iMac using latest version of MacOS Sierra and simply want to quit the Parallels app before Time Machine begins it's nitely backup and then relaunch Parallels after Time Machine has completed the backup. I've tried using the following scripts below, however when executed both produce the following error "AppleEvent timed out. (-1712)". Here's where it gets really strange, both scripts work perefectly just so long as the screen is awake, but if my computer has been idle for a while and the screen is asleep, I get the previous error. I even tried creating an automator script by recording my cursor movements and it tested fine while the screen was awake, but again failed once the computer was idle and the screen went to sleep...

    tell application "Parallels Desktop" to quit

    tell application "Parallels Desktop" to activate

    Any ideas,
    Thanks so much!
    Chuck

    Model: iMac 2011
    Browser: Safari 602.1
    Operating System: Mac OS X (10.10)
     

Share This Page