Script Debugger is not allowed assistive access

Just upgraded from v6 to v7. I don’t know if this script works in v6 or not, didn’t try it before upgrading. I get the dreaded “System Events got an error: Script Debugger is not allowed assistive access.” error, even though I went into System Preferences, deleted the old app from the list, added the new one and granted accessibility.

Here’s the script:

activate application "SketchUp"
tell application "System Events"
	tell process "SketchUp"
		get value of attribute "AXSelectedChildren" of list 1 of scroll area 1 of scroll area 1 of browser 1 of window 1
		
	end tell
end tell

Screenshot:

image

Any ideas? Thanks.