tell application "System Events"
tell application "System Preferences"
activate
(*
# Code used to grab the anchor's names
tell pane id "com.apple.preference.desktopscreeneffect"
name of its anchors
--> {"DesktopPref", "ScreenSaverPref"}
end tell
*)
reveal anchor "desktopPref" of pane id "com.apple.preference.desktopscreeneffect"
delay 0.5
end tell -- application "System Preferences"
tell process "System Preferences"
tell window 1 -- "Desktop"
set currentBackgound to value of first static text of first tab group
end tell
end tell -- process "System Preferences"
tell application "System Preferences" to quit
end tell -- application "System Events"
currentBackgound