We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Slide count inconsistent

Two nearly identical files (attached) return different sizes.

Kemira Fertilizers Limited_318EF.ppt correctly returns size=2 (one slide + one master)

Kemira Fertilizers Limited_35F45.ppt incorrectly returns size=1

Aspose Slides Java

source = new FileInputStream(pptPath);
Presentation pres=new Presentation(source);
int presSize = pres.getSlides().size()

This is causing issues as I need to iterate through all slides, including masters.

Dear cstuart,

Actually, there is just one slide in Kemira Fertilizers Limited_35F45.ppt and two slide masters (MainMaster).

So, if you want to calculate the total number of slides including

1- Normal Slides

2- Slide Masters

3- Title Masters

You will calculate them like this

int totalSlides=pres.getSlides().size() + pres.getMainMasters().size();

Note, title masters are found in pres.getSlides() and slide masters are found in pres.getMainMasters()