Quantcast
Channel: NPOI
Viewing all articles
Browse latest Browse all 1621

Closed Issue: Issue with 2.0 Beta: Get an non-Closing Element error [11085]

$
0
0
I have a situation where I have to open several XLSM files. Only about 50% of them work with the NPOI 2.0.
 
I get a failure similar to the following: The 'br' start tag on line 19 position 12 does not match the end tag of 'font'. Line 20, position 9.
 
The relevent stack trace is as follows:
 
System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Xml.XmlException: The 'br' start tag on line 19 position 12 does not match the end tag of 'font'. Line 20, position 9.
at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.Throw(String res, String[] args)
at System.Xml.XmlTextReaderImpl.ThrowTagMismatch(NodeData startTag)
at System.Xml.XmlTextReaderImpl.ParseEndElement()
at System.Xml.XmlTextReaderImpl.ParseElementContent()
at System.Xml.XmlTextReaderImpl.Read()
at System.Xml.XmlLoader.LoadNode(Boolean skipOverWhitespace)
at System.Xml.XmlLoader.LoadDocSequence(XmlDocument parentDoc)
at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace)
at System.Xml.XmlDocument.Load(XmlReader reader)
at System.Xml.XmlDocument.LoadXml(String xml)
at NPOI.XSSF.UserModel.XSSFVMLDrawing.Read(Stream is1)
at NPOI.XSSF.UserModel.XSSFVMLDrawing..ctor(PackagePart part, PackageRelationship rel)
--- End of inner exception stack trace ---
at System.RuntimeMethodHandle._InvokeConstructor(IRuntimeMethodInfo method, Object[] args, SignatureStruct& signature, RuntimeType declaringType)
at System.RuntimeMethodHandle.InvokeConstructor(IRuntimeMethodInfo method, Object[] args, SignatureStruct signature, RuntimeType declaringType)
at System.Reflection.RuntimeConstructorInfo.Invoke(BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at System.Reflection.ConstructorInfo.Invoke(Object[] parameters)
at NPOI.XSSF.UserModel.XSSFFactory.CreateDocumentPart(POIXMLDocumentPart parent, PackageRelationship rel, PackagePart part)
--- End of inner exception stack trace ---
at NPOI.XSSF.UserModel.XSSFFactory.CreateDocumentPart(POIXMLDocumentPart parent, PackageRelationship rel, PackagePart part)
at NPOI.POIXMLDocumentPart.Read(POIXMLFactory factory, Dictionary`2 context)
at NPOI.POIXMLDocumentPart.Read(POIXMLFactory factory, Dictionary`2 context)
at NPOI.POIXMLDocument.Load(POIXMLFactory factory)
at NPOI.XSSF.UserModel.XSSFWorkbook..ctor(Stream is1)
 
I found that the EPPlus Excel library is able to read all the files without issue. I prefer NPOI but have to have a working solution by the next 2 weeks. Hope there is an easy fix for the Alpha release.
 
For proprietary reasons I cannot attach the XLSM file. Thanks!

Viewing all articles
Browse latest Browse all 1621

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>