Copy link to clipboard
Copied
I have some circled textframes which I want to thread together using script and in each text frame I would like to place a counter of my choice. The counter is a number which I want to give manually.
Some examples of the counter is:
ex1: A-2234 onwards ...eg A-2235, A2236, A-2237 respectively in separate text frames.
ex2: B-0001 onwards...eg B-0002, B-0003, B-0004 respectively in separate text frames.
I have written a script to thread the frames but its threading hapazardly.
I have attached a screenshot with before and after run of the script. Also when the script ends, it gives an error.
Here is the script. It just threads. Once threading is perfect, I will place the counters using a variable.
frames = app.selection;
//alert(frames.length);
for(i=0;i<frames.length;i++){
frames[i].nextTextFrame = frames[i+1];
}
Currently the matter is in one page. It may run through multiple pages.
What mistake am I doing ?
Thanks
@Robert at ID-Tasker I have come up with the following script where I have followed process mentioned by @Laubender and assigned the story to frame by the process suggested by you, but still it shows only 1 \n char in first frame only. I have tried with 5 textframes only for testing. Screenshot of the output is attached.
var output = String('\n', 5);
By @shahidr100
Looks like this doesn't work as per example I've found on some website, sorry.
And you should use '\r' rather than '\n'.
Thi
...Copy link to clipboard
Copied