Using Tables of Word Processing Documents as Data Sources

Note
The example reads the shop data described in The Business Layer.

Using Tables of Word Processing Documents as Data Sources

Following classes are added in GroupDocs.Assembly.Data namespace:

The Recipe

  • Define template and output report documents
  • Assemble a document using the external document table as a data source

Download

Data Source Document

Template

The Code

from groupdocs.assembly import DataSourceInfo, DocumentAssembler
from groupdocs.assembly.data import DocumentTable, DocumentTableOptions

options = DocumentTableOptions()
options.max_row_index = 3
table = DocumentTable("managers.docx", 1, options)

assembler = DocumentAssembler()
assembler.assemble_document("importing-word-processing-table-into-presentation.pptx", "importing-word-processing-table-into-presentation-report.pptx", DataSourceInfo(table, "table"))

The following sample file is used in this example: importing-word-processing-table-into-presentation.pptx

The following sample file is used in this example: managers.docx

Binary file (PPTX, 34 KB)

Download full output

Close
Loading

Analyzing your prompt, please hold on...

An error occurred while retrieving the results. Please refresh the page and try again.