GetChildNodes method doesn’t lists the content control if content control has section break continuous.
- Block-level - Among paragraphs and tables, as a child of a Body, HeaderFooter, Comment, Footnote or a Shape node.
- Row-level - Among rows in a table, as a child of a Table node.
- Cell-level - Among cells in a table row, as a child of a Row node.
- Inline-level - Among inline content inside, as a child of a Paragraph.
- Nested inside another StructuredDocumentTag.
Unfortunately, this feature is not compatible with our document model. We apologize for your inconvenience.
Starting from Aspose.Words 20.7, you can read the content control that contains the section break.We have added read only properties for content control that contains the section break in Aspose.Words 20.7. You can find the detail of these properties from here:
Please use following code example to get the title of content controls. Hope this helps you.
var doc = new Document(MyDir + "my_sample.docx"); foreach (StructuredDocumentTagRangeStart tag in doc.GetChildNodes(NodeType.StructuredDocumentTagRangeStart, true)) Console.WriteLine(tag.Title); foreach (StructuredDocumentTag tag in doc.GetChildNodes(NodeType.StructuredDocumentTag, true)) Console.WriteLine(tag.Title);