Hello team.
We started encountering the exception “Cannot insert a node of this type at this location” in the version Aspose.Word 25.1 , as well as in the latest released version 25.3.
Note that this seems to be possible regression as it did not happen up to version 24.10.
Attached is the zip , containing the following:
DocWithTwoContentControls.docx - input word document with two Rich text controls
testSampleWordContent.html - small sample grid that is used to refresh second content control in the word doc;
WordContainerManagerTest.java - small main test that can be run as a standalone Java program;
WordContainerManager.java - small sample code that attempts to refresh content control;
AsposeWordUtility.java - supplemental helper program used by WordContainerManager
Aspose24_10_versus_24_11.png - image illustrating the issue when run with Aspose.Word 24.10 version 24.11 under Linux OS;
Aspose25_03.png - similarly, results of running the test with Aspose.Word library 25.3
Environment details:
java full version 1.8.0_441-b07
OS - Oracle Linux 7 Update 4
steps to reproduce:
- compile AsposeWordUtility: javac -cp .:commons-io-2.11.0.jar:aspose-words-25.1.jar AsposeWordUtility.java
- compile WordContainerManager: javac -cp .:commons-io-2.11.0.jar:aspose-words-25.1.jar WordContainerManager.java
- compile WordContainerManagerTest: javac -cp .:commons-io-2.11.0.jar:aspose-words-25.1.jar WordContainerManagerTest.java
- run WordContainerManagerTest: java -cp .:commons-io-2.11.0.jar:aspose-words-25.1.jar WordContainerManagerTest
Please let us know it you need additional details.
Thank you.
toAspose_CannotInsertNode.zip (719.9 KB)