• 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: Kill the screen saver
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Kill the screen saver


  • Subject: Re: Kill the screen saver
  • From: Gary Beberman <email@hidden>
  • Date: Mon, 23 Sep 2002 02:32:29 -0700

Timothy:

I can get you one step closer on this. But, I have a similar problem
and it hasn't helped.

set killProcess to (paragraph 1 of (do shell script "ps -aex | grep
ScreenSaver.framework | grep -v grep | awk '{ print $1 }'"))
set killResult to do shell script ("kill -9 " & deadProcess)

This will kill the Screen Saver. However, my subsequent 'tell
application "Finder"' line fails with an "application not running"
command.

Gary
At 9:55 AM -0400 9/12/02, Timothy K. Wilkinson wrote:
>I'm in a lab situation using OS X 10.1.5. I need to have machines log out
>after a certain period of inactivity. I've got a Perl script running that
>checks for the screen saver and if it's active it runs an AppleScript that
>logs off the user. Works wonderfully.
>
>Here's the kicker. I'm trying to give users warning that the machine is
>about to log off so they can save work using a dialog box. The problem is
>when the dialog box comes up the screen saver is still running and the user
>can't see it.
>
>I've tried things such as:
>
>tell app "logout"
>activate
>end tell
>
>tell app "ScreenSaverEngine"
>quit
>end
>
>but nothing works. I've also tried:
>
>Tell app "Finder"
>set app "logout" to frontmost
>end tell
>
>no success.
>
>Anyone have any ideas on who to kill the screen saver through AppleScript?
>
>Thanks,
>
>
>Tim Wilkinson
>ITC-ACHS
>University of Virginia
>email@hidden
>email@hidden
>_______________________________________________
>applescript-users mailing list | email@hidden
>Help/Unsubscribe/Archives:
>http://www.lists.apple.com/mailman/listinfo/applescript-users
>Do not post admin requests to the list. They will be ignored.
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Scroll arrows
      • From: Shane Stanley <email@hidden>
References: 
 >Kill the screen saver (From: "Timothy K. Wilkinson" <email@hidden>)

  • Prev by Date: Re: I have a solution to creating a file and setting the creator in AS
  • Next by Date: capturing e-mail text strings to http posting
  • Previous by thread: Kill the screen saver
  • Next by thread: Scroll arrows
  • Index(es):
    • Date
    • Thread