• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: aborting a running script
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: aborting a running script


  • Subject: Re: aborting a running script
  • From: Laine Lee <email@hidden>
  • Date: Mon, 28 Feb 2011 09:08:43 -0600
  • Thread-topic: aborting a running script

On 2/28/11 6:31 AM, "Jim Brandt" <email@hidden> wrote:

> I have a question about aborting a running script.
>
> When invoked from the script menu, which application or process is in control
> of running the script? Is it System Events? Is there a graceful way to cancel
> the script while it is running?
>
> I have several scripts that walk file directories, and after starting them,
> they take longer than I intended and I want to shut them down. So I'm looking
> for a way to do this without putting dialog in that needs responded to every
> so often.
>
> Is there an accepted way to do this. Stopping a process from Activity Monitor?
>

I use the one of these shell commands to stop all running scripts, but it's
more or less a last resort for cleaning up after accidents.

Leopard or Snow Leopard:

sudo killall AppleScript\ Runner

AppleScript version:
do shell script "sudo killall AppleScript\\ Runner" with administrator
privileges

Older systems

sudo killall System Events
>
> Also, does anyone have a way to build a list of all files regressively in
> folders below the current level?
>
> i.e.
>
> folder 1
> file 1
> file 2
> file 3
> folder 2
> file 4
> file 5
> folder 3
> folder 4
> file 6
> file 7
>
> I want a list of the paths of all files (and folders) shown. Can the Finder
> give this in a single command?
>

You have plenty of good replies to this part. I've also used the folder
recursion method from the essential subroutines, but that's very old stuff.


Laine Lee


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: aborting a running script
      • From: KOENIG Yvan <email@hidden>
References: 
 >aborting a running script (From: Jim Brandt <email@hidden>)

  • Prev by Date: Re: aborting a running script
  • Next by Date: Re: aborting a running script
  • Previous by thread: Re: aborting a running script
  • Next by thread: Re: aborting a running script
  • Index(es):
    • Date
    • Thread