• 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
Dealing with Sliders...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Dealing with Sliders...


  • Subject: Dealing with Sliders...
  • From: email@hidden
  • Date: Fri, 10 Feb 2006 13:38:27 -0700

I need to write an Applescript that deals with the Energy Saver Preference Pane
and sets the machine to never sleep and never put the hard disk to sleep.

Here is what I have so far:


tell application "System Preferences"
	activate
	set current pane to pane "com.apple.preference.energysaver"
end tell


tell application "System Events"
	tell process "System Preferences"

		set theSlider to slider 1 of tab group 1 of group 1 of window "Energy Saver"
		set the value of theSlider to "Never"
	end tell
end tell

Here is the error:
System Events got an error: NSReceiverEvaluationScriptError: 4

It highlights the Slider 1 section of the first set line.

Does anybody have any thoughts on how I can control these sliders?

-Jason

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Dealing with Sliders...
      • From: kai <email@hidden>
  • Prev by Date: Re: File exists on a posix path
  • Next by Date: Re: File exists on a posix path
  • Previous by thread: Re: File exists on a posix path
  • Next by thread: Re: Dealing with Sliders...
  • Index(es):
    • Date
    • Thread