10.4 - Toggle Universal Access Grayscale

Just in case anyone might find it useful…

!----cut here----

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

tell application "System Events"
	tell process "System Preferences"
		set visible to false
		tell window "Universal Access"
			tell tab group 1
				tell checkbox 1
					click
				end tell
			end tell
		end tell
	end tell
end tell
set pathToPrefPane to (path to system folder as string) & "Library:PreferencePanes:UniversalAccessPref.prefPane:"

tell application "System Events"
	open file pathToPrefPane
	tell process "System Preferences"
		activate
		click checkbox 1 of tab group 1 of window "Universal Access"
	end tell
end tell