Shutdown PowerBook using AppleScript

Hy,

is it possible to shutdown the Mac using Applescript. Thanks for your help.

regards
Sigi

Sigi,

How about:


tell application "Finder"
	shut down
end tell

{sigh]

Not under Mac OS X

Use:

tell application “System Events”
shut down
end tell

instead.

The Finder may not be running under Mac OS X, and should only be used for file/disk-level manipulation. System Events is the faceless, background application that should be used for all System-level actions.

Camelot,

Thanks, I have been following this board for long enough that I should have known this. It is hard to break old habits.

Andy