Copy link to clipboard
Copied
I needs to add enter mark after all inline tables via script. Please advice.
Hi priyak7746321 ,
check the value of storyOffset of a table in its story object:
Adobe InDesign CS6 (8.0) Object Model JS: Table
Example with the first table of the first story of the active document:
app.documents[0].stories[0].insertionPoints
[
app.documents[0].stories[0].tables[0].storyOffset.index+1
].contents = "\r";
What I'm doing here?
I tell the first insertion point after the table to get new contents.
A paragraph character.
storyOffset of a table is the insertion point before the table.
story
...Copy link to clipboard
Copied
Hi priyak7746321 ,
check the value of storyOffset of a table in its story object:
Adobe InDesign CS6 (8.0) Object Model JS: Table
Example with the first table of the first story of the active document:
app.documents[0].stories[0].insertionPoints
[
app.documents[0].stories[0].tables[0].storyOffset.index+1
].contents = "\r";
What I'm doing here?
I tell the first insertion point after the table to get new contents.
A paragraph character.
storyOffset of a table is the insertion point before the table.
storyOffset.index is the position of that insertion point in its parent story.
storyOffset.index +1 is the position of the next insertion point.
Regards,
Uwe
Copy link to clipboard
Copied
As stated by Laubender​,
This how you can achieve this:
var allStory = app.documents[0].stories;
for(var s = 0; s < allStory.length; s++){
for(var t = 0; t < allStory
.tables.length; t++){allStory
.insertionPoints[allStory.tables.storyOffset.index+1].contents = "\r"; }
}
Best
Sunil