Running a persistent AppleScript App

(I’ve just purchased Script Debugger cause I wanted a better editing experience than what Apple’s Script Editor offers)

I’ve got a applescript (app) that sits in the background (but isn’t a background only app) which periodically pings a couple of IP addresses, and logs the success or failure to a text file.

Now to my problem:

I can’t figure out (although I’m sure I’ve just missed seeing it) how to use SD’s debugger feature(s) to actually run the script so it goes into the On Idle handler every x seconds and pings the defined IP addresses.

I guess, is it possible to actually follow the script steps as they execute further than just the On Run handler, and one time through the On Idle handler ?

tia

furbies

There are two approaches:

  1. You can use Script Debugger’s ability to invoke an idle handler like this:

    This allows you invoke your script’s on idle handler directly.

  2. You can save your applet with debugging enabled. Then, each time the on idle handler is invoked, Script Debugger will come forward to debug it for you. Just take care to disable debugging and re-save your script when you are done to turn this feature off.

2 Likes