Free Support Forum - aspose.com

Getting part of file is missing after slides merge

Hi,

Greetings.

We are using 'aspose.slides' in our project to clone mutiple reports as powerpoint slides to single presentation. In many cases Cloning multiple slides to final powerpoint presenation is working fine. But in one scenario final powerpoint is creating but when i try to open its giving message like that 'Power point can't open because part of file is missing'. I have not got any clue on this. And details as follows.

From our application around 2060 individual slides are being created based data input and finally creating one final powerpoint file using 'CloneSlide' function.

if (fi.Exists && Regex.IsMatch(fi.Extension.ToLower(), supportedFile))

{

Presentation srcPres = new Presentation(filePath);

SortedList srList = new SortedList();

for (int slides = 1; slides <= srcPres.Slides.Count; slides++)

{

srList.Clear();

srcPres.CloneSlide(srcPres.GetSlideByPosition(slides), newPres.Slides.LastSlidePosition + 1, newPres, srList);

}

}

newPres.Slides.Remove(newPres.GetSlideByPosition(1));

SetLicenseForSlides();

srcPres.DeleteUnusedMasters();

srcPres.DeleteHandout();

FileUtilities.CreateDirectory(outputPath);

srcPres.Write(outputPath);

the same code is running fine for other scenarios, but only for this where more than 2000 slides are clubbing together, in this case around 2060 slides merging to gether.

As it is bit urgent, requesting you to provide your suggestions on this. Your help on this would be appreciated.

Thanks

Ravikiran

Dear Ravikiran,

Thanks for your interest in Aspose.Slides.

I have observed the code snippet shared by you and feel no problem in it. It would be really helpful, if you can please kindly share the source presentations for necessary investigation to identify and reproduce the issue on our end. One suggestion that I would like to make is that same SortedList object can be utilized for all slides residing in same presentation and that are to be cloned.

Thanks and Regards,