Hi,
I am facing one issue while trying to convert few PPT to PPTX in .Net platform.
Please find my code logic below:
- I have saved the content of an existing PPT as a binary in a SQL database (DB1) - SQL Server 2008.
- Take the backup of DB1
- Moved the DBI backup and restored to a new environment DB2 (SQL Server 2012)
- Custom code, using ASPOSE, to create the PPTX file from the content of DB2 database.
PowerPoint found a problem with content in xxxxx.pptx.
PowerPoint can attempt to repair the presentation.
If you trust the source of this presentation,click repair.
On Clicking repair the file is getting opened.
Please note that the file contains standard image.
Please note that I am using ASPOSE TOTAL lic (purchased) and this working fine with other PPT/PPTX.
This is happening with few PPT.
I am attaching one sample PPT here.
Please advise.
===================
Please find the code snippet (conversion):
byte[] fileInBinary = tblContent_Irow.BLOBContent;
Stream stream = new MemoryStream(fileInBinary);
Stream oStream = new MemoryStream();
case “ppt”:
using (Presentation pres = new Presentation(stream))
{
//Saving the PPT presentation to PPTX format
if (pres.VbaProject != null)
{
pres.VbaProject = null;
}
pres.Save(oStream, Aspose.Slides.Export.SaveFormat.Pptx);
nwstrFileRelativeURl = strFileRelativeURl.Substring(0, strFileRelativeURl.LastIndexOf(’.’)) + “.pptx”;
}
break;