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

Free Support Forum - aspose.com

ODP 1.3 files created in LibreOffice 7.0 are not supported

See the attached Images.odp.zip (1.9 MB). Latest LibreOffice saves in ODF 1.3 format by default.

@volozyko

Can you please share that what issue you are having along with API version and used sample code with us.

Ok. With relation to ODP format we use Aspose.Slides for .Net version 20.4. The code snippet is the following.

public unsafe void render(System.IO.Stream inputStream, void* buffer, int bufferSize)
{
    var doc = (new Aspose.Slides.PresentationFactory()).ReadPresentation(inputStream);

    var slide = doc.Slides[0];
    var size = new System.Drawing.Size(doc.SlideSize.Size.Width, doc.SlideSize.Size.Height);

    var bitmap = slide.GetThumbnail(size);
    var lockRect = new System.Drawing.Rectangle(0, 0, bitmap.Width, bitmap.Height);
    var bitmapData = bitmap.LockBits(lockRect, System.Drawing.Imaging.ImageLockMode.ReadOnly, bitmap.PixelFormat);
    try
    {
        IntPtr bmpPtr = bitmapData.Scan0;
        var bytesToCopy = bitmapData.Stride * bitmap.Height;
        if (bytesToCopy > bufferSize)
        {
            throw new Exception("Error");
        }

        for (int i = 0; i < bytesToCopy; ++i)
        {
            ((byte*)buffer)[i] = ((byte*)bmpPtr.ToPointer())[i];
        }
    }
    finally
    {
        bitmap.UnlockBits(bitmapData);
    }
}

The exception that I’m seeing in the line with ReadPresentation is System.FormatException: 'Input string was not in a correct format.'

Same thing happens with Aspose.Slides for .Net 20.9.

@volozyko

I have created an issue with ID SLIDESNET-42185 in our issue tracking system to further investigate and resolve the issue. This thread has been linked with the issue so that you may be notified once the issue will be fixed.

The issues you have found earlier (filed as SLIDESNET-42185) have been fixed in this update.

It works. Thanks.

@volozyko

Thank you for your positive feedback.