System.ArgumentException raised when saving a document with an object in HtmlFixed format

Hi,

we noticed an exception when saving a document with SaveFormat.HtmlFixed. The document cotains a “Designer 3.1” object. Word itself renders the element. When saving to PDF with Aspose it is partly rendered, partly contains a placeholder symbol.
Saving with SaveFormat.Html also works without exception but the placeholder symbol.

The document was submitted by a customer. I myself don´t know what “Designer 3.1” format is, just found very old tools for SVG editing. If embedding the graphic is not supported by Aspose, this is fine for us, however we would expect the placeholder symbol to be added into the SaveFormat.HtmlFixed as well, instead of the exception.

Testcode

            var doc = new Document(@"S:\tmp\doc\test.docx");
            doc.Save(@"S:\tmp\doc\out\out.html", SaveFormat.HtmlFixed);

Testfile
test.docx (55.8 KB)

Thanks for your help

@Serraniel Thank you for reporting the problem to us. I have managed to reproduce it on my side. For sake of correction it has been logged as WORDSNET-23460. We will keep you informed and let you know once the issue is resolved.
As a temporary workaround you can use MetafileRenderingMode.Bitmap like shown in the following code:

Document doc = new Document(@"C:\Temp\in.docx");

HtmlFixedSaveOptions opt = new HtmlFixedSaveOptions();
opt.MetafileRenderingOptions.RenderingMode = MetafileRenderingMode.Bitmap;

doc.Save(@"C:\Temp\out.html", opt);

Thanks, setting the option fixed the workaround. I also tried the behaviour of the Bitmap rendering mode when saving as PDF and can confirm it fixes the placeholder symbols and does a better result as well.

@Serraniel It is perfect that workaround works for you. We will keep you informed and let you know once the original issue is resolved.

The issues you have found earlier (filed as WORDSNET-23460) have been fixed in this Aspose.Words for .NET 22.3 update also available on NuGet.

Hi,

we noticed a follow-up issue, related to the previous fix. Until now, we still have applied the provided workaround in our code, which is causing a different issue on a different document and different scenario. I will open a new thread for that soon.

However, we tried to remove the provided workaround and noticed, that there are optical differences when the workaround is removed. Same with PDF.

Please see the attached files,
out.html and out.pdf are created using my original posted code.
out2.html and out2.pdf are created including the workaround.

Without the workaround it still looks slightly wrong in current Aspose.Words version.

Thanks for your help.

out.zip (597.5 KB)

Examples produced on Win 10 22H2 Build 19045.3570 using .Net 7

@Serraniel
We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s): WORDSNET-26109

You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.

The issues you have found earlier (filed as WORDSNET-26109) have been fixed in this Aspose.Words for .NET 23.11 update also available on NuGet.