Hi,
I am currently trying to script Xtags from em software in combination with InDesign CS3.
So far I have no problem to import Xtags into a text frame using the «get text with Xtags command», it works like a charm, but the opposite command - exporting Xtags - gives me a headache.
The Users Guide states that «save text with Xtags» and «save with Xtags» are different commands.
And while I get «save text with Xtags» to act as I want to (it exports Xtags files as shown in the sample code below), I don’t see how to execute «save with Xtags».
The document states that this command ignores the selection and exports the whole referenced object. But how to reference it?
I’d love to see some sample code…
Thanks so much!
Martin
set xtagsfilepath to (((path to desktop) as text) & "Test.xtg")
tell application "Adobe InDesign CS3"
tell document 1
tell page 1
set txtframe to text frame "Listing_p1"
tell txtframe
set inspoint to insertion point -1 of parent story of txtframe
select inspoint
set contents to ""
end tell
end tell
save text with Xtags to xtagsfilepath encoded as utf8 without style definitions, separate tags and full list elements
end tell
end tell