Hey Ed,
This just builds on previous work:
----------------------------------------
tell application "System Events"
tell application process "Acorn"
tell front window
if its subrole is "AXDialog" then
if (get its static text) = "Apply Operation" then
tell button "Cancel"
perform action "AXPress"
end tell
end if
end if
end tell
end tell
end tell
----------------------------------------
Use a Focussed Window Changes trigger. There are 4 types to choose from.
-Chris