There is cursor on the page (one page - one text frame) in inDesign.
Is it possible with JavaScript to get number/id of current page (text frame) with cursor?
Probably solution app.activeWindow.activePage.name
returns number of the page on the screen, but not number of page/text frame with cursor.
For example: if cursor set on page 3, but we see page 20 on the screen, app.activeWindow.activePage.name
returns 20.