Hi,
My question is rather simple,
is there any functionality that returns an object by x and y pos?
E.g. I click on 120x and 250y, and on that coördinate there is a textframe,
is it possible to fetch that object just by giving the x and y ?
(Via scripting, or java, whatever is possible)
Kind regards
Scripting can't help you, because a script cannot determine if the user clicked anywhere, lest on what position.
(A crude way to do this would be to pop up a dialog, asking for the coordinates. If the coordinates are known, it's easy to get a list of objects that are under that position. But note: objects, plural. As always, this has to be thought about ahead. The OP only mentions 'an object'; what if there are more than one? What about a group -- return the group itself, or "the" object (or objects) inside the group? What about items on a master page?
As always, it would help if the OP could clarify what would be done with the object(s) after 'finding' them at a certain location. Surely this would serve a deeper purpose, other than "just to see what is there"?)
Well I know how to get the input done,
I just don't know how to get the object or objects under that position. So that is my biggest question.
After I know that I will figure out how to deal with the return(s) I will get.
E.g if I get an object that contains another object and then a textframe, I would handle upon that.
Same goes if I encounter another kind of frame or object.
Thanks in advance!
North America
Europe, Middle East and Africa
Asia Pacific