I have a single textframe with multiple xml tags within formated by paragraph and character styles.
I want to access the xml tag attribute of the xmltag, related to my first 5 characters....
How to do it?
Or second approch, i need to find first and last xml tag on the page.
Try this (second approach),
Select any text frame and try the below code:
alert(app.selection.lines.words.associatedXMLElements.markupTag.name)\\first XML tag alert(app.selection.lines[-1].words[-1].associatedXMLElements.markupTag.name)\\second XML tag