I’m using Aspose.Words for .NET version 15.3.0.0
I have a document (“test.docx”) that contains a couple of textboxes. I try the following code to fetch the number of textboxes:
var count =Surprisingly, count is 0. But there’s more.
document
.GetChildNodes(NodeType.Shape, true)
.Cast()
.Count(s => s.ShapeType == ShapeType.TextBox);
I’ve created a blank docx using LibreOffice Writer (“test_copy.docx”) and copy-pasted all textboxes from test.docx to test_copy.docx. I’ve run the same code for both files and got this:
test.docx: 0I understand the fact that these files are different on binary level, but LibreOffice writer allows me to manipulate textboxes in both files (for example, chage the size of a textbox).
text_copy.docx: 10
Is there a solution for this problem?