I’ve got a similar problem with normal document properties, this works in Word:
______________________________________________________________________
There's no need to repeat through like that when you know what property you want to look at.
These both work with the apps from Office 2011.
----------------------------------------------------------
tell application id "com.microsoft.Word" # USE ACTIVE DOCUMENT – IT'S FASTER. tell active document if value of document property "keywords" = "HARRY" then set value of document property "keywords" to "FRED" else set value of document property "keywords" to "HARRY" end if end tell end tell
----------------------------------------------------------
tell application id "com.microsoft.Powerpoint" tell active window tell its presentation if value of document property "keywords" = "HARRY" then set value of document property "keywords" to "FRED" else set value of document property "keywords" to "HARRY" end if end tell end tell end tell
----------------------------------------------------------
Figuring out PP's different syntax was a bit pesky, and without Script Debugger it would have been worse.
|