I have written an script for duplicate target of Xcode project and got Error "Xcode got an error: AppleEvent handler failed.
My script is:
tell application "Xcode"
activate
delay 3
tell active workspace document
set my_project to (get first project)
tell my_project
set make_target to (get first target of my_project)
set target_name to "ScriptDemoCopy"
tell application "System Events"
keystroke "d" using {command down}
--set my_new_target to make target with data make_target with properties {name:target_name}
end tell
end tell
end tell
end tell Can someone tell me where am i wrong ?
Thanks in advance.