Bug with index entry
If you select a word after a table (»sit« in InDesign document: https://adobe.ly/2X0wXOi) and create an index entry using script, the page reference will be created after the word (under certain circumstances).
var _doc = app.activeDocument;
var _docIndex;
if(_doc.indexes.length === 0) {
_docIndex = _doc.indexes.add();
} else {
_docIndex = _doc.indexes.firstItem();
}
var textObj = app.selection[0];
var _parentTopic = _docIndex.topics.add("Topicname");
var _pageRef = _parentTopic.pageReferences.add(textObj);
– word before that, everything's correct.
– tables with 3 or more rows
– the more table rows the more offset
Thanks for reporting
We are reviewing the issue
-InDesign Team
-
Ashrafali R commented
It should be cleared at the earliest!
-
Jeremy Bowman commented
If this was an old problem in January 2020, it's an even older problem in April 2023! Just came across it yesterday!
-
Peter Kahrel commented
An old problem. It gets worse the more tables there are in a document. If you add a page reference after, say, 20, tables, the page reference can end up in the next sentence or paragraph.
-
Uwe Laubender commented
Hi Roland,
I can confirm the bug.
Just tested with InDesign CC 2019 version 14.0.2 on Windows 10.See also this discussion at Adobe InDesign Scripting Forum:
Crazy bug with index entry
drerol74 Jun 23, 2019 11:39 AM
https://forums.adobe.com/message/11135239#11135239Reagrds;
Uwe Laubender
( ACP )