LayoutCollector.GetStartPageIndex returns Incorrect Page Number for Shape using Java

Hi Team.

I am trying to get all pictures from a word document and sort them by their position. I am using the following code to achieve that:

LayoutCollector layoutCollector = new LayoutCollector(asposeDocument);
LayoutEnumerator layoutEnumerator = new LayoutEnumerator(layoutCollector.getDocument());
Object renderObject = layoutCollector.getEntity(asposeShape);
layoutEnumerator.setCurrent(renderObject);
int pageNumber = layoutEnumerator.getPageIndex();
double top = layoutEnumerator.getRectangle().getX();
double left = layoutEnumerator.getRectangle().getY();

The results are good in common. But I found a few documents where the page number is incorrect for some text boxes. Could you take a look at the example? Is it something wrong with the document? Or is there a bug in aspose?

Here is the document: example.zip (3.2 MB)
The page number of Fig.6 is 2. But in document it is on the page 3.

Thank you in advance,
Svetlana

@skorpusova

We have tested the scenario and have managed to reproduce the same issue at our side. For the sake of correction, we have logged this problem in our issue tracking system as WORDSNET-21819. You will be notified via this forum thread once this issue is resolved.

We apologize for your inconvenience.

A post was split to a new topic: LayoutCollector returns Incorrect Page for Shape