How do I abort if dashboard = as overlay

tell application “System Preferences”
activate
reveal pane (“Mission” & linefeed & “Control”) # Yes, there is a linefeed in the name !
end tell

Would someone, more experienced than I am, please tell me, is it possible to abort script if AS OVERLAY is selected in Dashboard / Mission Control. If it is possible to abort, what would the script look like? Thank you much.