We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

System.ArgumentException on WordDocument.Open : An item with the same key has already been added.

Hi there,

I'm having some trouble opening a specific .DOCX word document. When called WordDocument.Open  we receive the following error (stack trace included),

System.ArgumentException: An item with the same key has already been added.
   at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add)
   at Syncfusion.DocIO.DLS.Convertors.Word2010Parser.ParseBookmarkStart(XmlReader reader, IWParagraph paragraph)
   at Syncfusion.DocIO.DLS.Convertors.Word2010Parser.ParseParagraph(XmlReader reader, IWParagraph paragraph)
   at Syncfusion.DocIO.DLS.Convertors.Word2010Parser.ParseBody(XmlReader reader, IEntity entity)
   at Syncfusion.DocIO.DLS.Convertors.Word2010Parser.ParseDocument(Stream stream)
   at Syncfusion.DocIO.DLS.Convertors.Word2010Parser.ParseDocument(Package package)
   at Syncfusion.DocIO.DLS.Convertors.Word2010Parser.ReadDocument(ZipArchive zipArchive, Package package, WordDocument document)
   at Syncfusion.DocIO.DLS.DocxReader.Read(WordDocument doc)
   at Syncfusion.DocIO.DLS.DocxReader.Read(String documentPath, WordDocument doc)
   at Syncfusion.DocIO.DLS.WordDocument.Open(String fileName, FormatType formatType, String password)

I'm calling the basic open method (single string param for the file location). Any light you could shed on this would be greatly received,

Kind Regards

Andy

3 Replies

DY Deivaselvan Y Syncfusion Team July 10, 2012 04:50 AM UTC

Hi Andy,

Thank you for your interest in Syncfusion products.

The information provided is insufficient to reproduce the reported issue on our side.
Kindly provide us with the sample/code snippet along with the input template document you have used to reproduce the mentioned exception issue, So that we can analyze the issue further and provide you with appropriate details.

Could you please report this issue through Direct Trac Developer Support System (https://www.syncfusion.com/account/login?ReturnUrl=%2fsupport%2fdirecttrac%2fincidents because you can take the advantage of the expertise of a dedicated support engineer and a guaranteed response time and we hope you will take advantage of this system as well. If you have already reported, please ignore this.

Please let us know if you have any questions.

Regards,
Deiva selvan



AC Andy Calvert July 10, 2012 08:22 AM UTC

Thank you for your reply.

As requested i have created a support ticket, i look forward to your reply


DY Deivaselvan Y Syncfusion Team July 11, 2012 06:31 AM UTC

Hi Andy,

Thank you for your update.

Our engineer will assist you shortly.

Please let us know if you have any questions.

Regards,
Deiva selvan


Loader.
Live Chat Icon For mobile
Up arrow icon