docx_form package

Subpackages

Submodules

docx_form.docx_form module

class docx_form.docx_form.DocxForm(file_path: str)

Bases: object

This is the one and only entry point for the DocxForm package. DocxForm holds all content controls for a given document and allows read and write operations on the document.

print_all_content_controls_and_form_fields()

This method prints all content controls and form fields in the document.

save(destination_path: Optional[str] = None)

This method saves the document to the destination path if a path is given. If not, the original file is overwritten. :param str destination_path: The full path to save the file to, defaults to None

Module contents