Hi Jang,
I hope you are doing well!
I am trying to understand how the script works and it is not clear to me what "oTexts[i].offset;" does. Could you please explain this?
In the meantime, I continued testing the script. When I expose all conditions, the script makes FM crash only when it approaches the last paragraph of the file. If I do not expose all conditions, this happens even earlier. So in the meantime, I can't test if it works on a book, although I included a call to the iterations.jsx file.
Wishing you best of luck!