How do you find the table closest to the insertion point?
All the examples I can find show how to find a table when you're already in one. But I need to be able to find the next table before or after the insertion point, even if it's sitting in regular text.
Presumably I need to find the absolute index of the start (and end, maybe) of the table in the story and compare it to that of the insertion point, but something like the following doesn't seem to give an index in the entire story:
