Mobile app version of vmapp.org
Login or Join
Kevin459

: How to change textframe creation order in Indesign I am writing a script for Indesign. In that script I am taking the contents of the textframes and save them to a database. Till here my

@Kevin459

Posted in: #Adobe #AdobeIndesign #Javascript

I am writing a script for Indesign. In that script I am taking the contents of the textframes and save them to a database. Till here my script works. However when looping between textframes script uses creation order. I want to save to database in question order.

Here is my script:

var myDocument = app.activeDocument;var frameList = myDocument.textFrames;
for (var i = 0; i < frameList.length; i++){
var txt=frameList[i].contents;
SaveToDB(txt);
}


So is there a way to change creation order of textframes

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Kevin459

1 Comments

Sorted by latest first Latest Oldest Best

 

@Miguel516

Yes, there is a way to change the "creation order", you simply need to rearrange the text frames in the Layers panel. The text frame at the lowest position in the stack will be treated as if it were created first, and the one at the highest position as if it were created last.

However, I know of no way to change this stack order via script (if somebody knows one, I would be curious to hear it).

So your choices are to either manually rearranging this stack order in the Layers panel and then run your script or to do what Jongware said, to sort it by the question numbers.

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme