Hi,
When running running 1 document mail merge at a time I have no errors. When running multiple jobs at at time. Completely independent of each other I run into the below error. This is causing issues as we need to generate 20,000 mail merged files.
My guess is it is linked to a static Dictionary under the covers.
System.InvalidOperationException: Operations that change non-concurrent collections must have exclusive access. A concurrent update was performed on this collection and corrupted its state. The collection's state is no longer correct.
at System.Collections.Generic.Dictionary2.FindEntry(TKey key) at System.Collections.Generic.Dictionary
2.TryGetValue(TKey key, TValue& value)
at .(Char )
at .(Int32 )
at .(Int32 )
at . (Int32 )
at . ( , Boolean )
at .( , , , Boolean )
at .(String , , Boolean )
at . (Boolean )
at . (Int32 , Boolean , Boolean )
at . (Int32 , Boolean )
at . (Int32 )
at Aspose.Words.Fields.FieldMergeField. ( , MailMerge )
at Aspose.Words.Fields.FieldMergeField. ( )
at Aspose.Words.Fields.FieldMergeField.86q6acmbfp2kjwdcs2q6rs3uwmqt2zc9 ()
at Aspose.Words.Fields.FieldMergeField.86q6acmbfp2kjwdcs2q6rs3uwmqt2zc9 (FieldStart , FieldSeparator , FieldEnd )
at .(FieldStart , FieldSeparator , FieldEnd )
at . ()
at . ()
at .VisitFieldEnd(FieldEnd )
at Aspose.Words.Fields.FieldEnd.Accept(DocumentVisitor visitor)
at Aspose.Words.CompositeNode.AcceptChildren(DocumentVisitor visitor)
at Aspose.Words.CompositeNode.AcceptCore(DocumentVisitor visitor)
at Aspose.Words.Paragraph.Accept(DocumentVisitor visitor)
at Aspose.Words.CompositeNode.AcceptChildren(DocumentVisitor visitor)
at Aspose.Words.CompositeNode.AcceptCore(DocumentVisitor visitor)
at Aspose.Words.Tables.Cell.Accept(DocumentVisitor visitor)
at Aspose.Words.CompositeNode.AcceptChildren(DocumentVisitor visitor)
at Aspose.Words.CompositeNode.AcceptCore(DocumentVisitor visitor)
at Aspose.Words.Tables.Row.Accept(DocumentVisitor visitor)
at Aspose.Words.CompositeNode.AcceptChildren(DocumentVisitor visitor)
at Aspose.Words.CompositeNode.AcceptCore(DocumentVisitor visitor)
at Aspose.Words.Tables.Table.Accept(DocumentVisitor visitor)
at Aspose.Words.CompositeNode.AcceptChildren(DocumentVisitor visitor)
at Aspose.Words.CompositeNode.AcceptCore(DocumentVisitor visitor)
at Aspose.Words.Body.Accept(DocumentVisitor visitor)
at Aspose.Words.CompositeNode.AcceptChildren(DocumentVisitor visitor)
at Aspose.Words.CompositeNode.AcceptCore(DocumentVisitor visitor)
at Aspose.Words.Section.Accept(DocumentVisitor visitor)
at Aspose.Words.CompositeNode.AcceptChildren(DocumentVisitor visitor)
at Aspose.Words.CompositeNode.AcceptCore(DocumentVisitor visitor)
at Aspose.Words.Document.Accept(DocumentVisitor visitor)
at . (Node )
at . (Node , Boolean , FieldType[] )
at . (Node , Boolean )
at . (Node )
at . (Node )
at Aspose.Words.MailMerging.MailMerge. ( )
at Aspose.Words.MailMerging.MailMerge.ExecuteWithRegions(IMailMergeDataSource dataSource)