This seems so basic I am embarassed to post the question, but here goes…
I imported into DevonThink (DT) some RTF items exported from Scrivener. Now I want to use AppleScript to set the meta data of the records in DT.
I parsed the original created and modified dates as text. They are formatted in a way that AppleScript understands and can coerce to a date object, which I assume is necessary to set these values in the DT records.
In a test script with no tell block, this compiles and runs:
set dateString to "December 13, 2020 at 3:36 PM" return date dateString
But within a tell block for DT, I get a compile error:
set createdDateObj to date createdDateString
Syntax Error: Expected end of line, etc. but found identifier.
and Script Editor has highlighted the
I noticed DT has a
date term, so I suspected a clash. Is there a trivial syntax fix?