Skip to content

How to get the section number a paragraph is in? #1321

@chribonn

Description

@chribonn

How can one iterate though docx.document.Document.paragraphs to get the section in which a paragraph resides?

I have a sample Word Document and would like to track particular styles paragraphs by Page number and section number.

[The document is at Word Document .

If the code is tracking style names starting with Column, the expected output would be as shown in https://github.com/chribonn/summariseDocx/blob/main/Test.md.

Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions