When converting an html document that contains svg with a path element that does not have a “d” attribute, a FileCorruptedException will be thrown. I’m using v18.2 of the library.
To duplicate, create an instance of a Document and load the following HTML:
<html><body><svg><path></path></svg></body></html>
The full exception is:
Aspose.Words.FileCorruptedException: The document appears to be corrupted and cannot be loaded. —> System.ArgumentNullException: Value cannot be null.
Parameter name: input
at System.Text.RegularExpressions.Regex.Matches(String input)
at ? .(String , ? )
at ? .( ? )
at ? .( ? , ? )
at ?? .( ? , ? , Boolean )
at ?? .( ? , ? , Boolean )
at ?? .( ? , ? )
at ? .()
at ? . ( , Boolean )
at ? .( , Boolean , ? )
at ? .( , Boolean )
at ? .( )
at ? .( )
at ? .( )
at ? .( )
at ? .(Stream , Encoding , DocumentBuilder )
at ? . ? ?()
at Aspose.Words.Document.(Stream , LoadOptions )
— End of inner exception stack trace —
at Aspose.Words.Document.(Stream , LoadOptions )
at Aspose.Words.Document.(Stream , LoadOptions )
at Aspose.Words.Document…ctor(Stream stream, LoadOptions loadOptions)
at ConsoleApplication7.Program.Main() in C: \temp\ ConsoleApplication7\ Program.cs: line 174