我正在使用InDesign CS6。
我有一个嵌套在一个组内的表。该组使用InDesign的脚本标签标记为“slug”。我正在尝试将信息插入该表的单元格中。
如果我定位“组1”,我就不使用标签就可以使用它,但如果布局中有任何其他组,则无法正常工作(显然不行)。
这是我的代码。请注意我在第7行上尝试定位该组的失败。有任何想法吗?
tell application "Adobe InDesign CS6"
set myDoc to active document
set colorMode to blending space of transparency preferences of myDoc
set docBleed to document bleed top offset of document preferences of myDoc
set docWidth to page width of document preferences of myDoc
set docHeight to page height of document preferences of myDoc
set slugGroup to (group whose label is "slug")
tell table 1 of text frame 1 of slugGroup of myDoc
set contents of cell 1 of row 2 to colorMode
set contents of cell 2 of row 1 to docWidth & " x " & docHeight
set contents of cell 2 of row 2 to docBleed
end tell
end tell
答案 0 :(得分:0)
我只是想通了。我需要针对FIRST小组。
tell myDoc
tell table 1 of text frame 1 of (first group whose label is "slug")