I have an old version of Aspose.Words (SubscriptionExpiry>20090707 LicenseVersion>2.2)
A program we haven’t touched for years is failing at the
Public Sub InsertDocumentAtBookmark()
with the following error
Cannot add a style because a style with the same name already exists.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.ArgumentException: Cannot add a style because a style with the same name already exists.
Source Error:
Line 164:
Line 165: ’ This creates a clone of the node, suitable for insertion into the destination document.
Line 166: Dim newNode As Node = importer.ImportNode(srcNode, True)
Line 167:
Line 168: ’ Insert new node after the reference node.
Source File: C:\Inetpub\taxiinsure\wwwroot\Reports\quote.aspx.vb Line: 166
I understand that this was a known issue
Quote from Aspose forum
"The issues you have found earlier (filed as 3658) have been fixed in this update.
Issue #3658 - “Cannot add a style because a style with the same name already exists” exception occurs during inserting one document into another.
The problem occurs when destination document contains a user defined style with a name of a built in style."
We don’t want to buy the newer version of Aspose because the one we have fulfils all of our requirements.
Could you advise how correct this problem.
Thank you
Jonathan Marsden