Generate sample report for document with variable
Leave feedback
Template Syntax
assembler = ga.DocumentAssembler()
dataSource = ga.data.XmlDataSource("datasource.xml")
DataSourceInfo = ga.DataSourceInfo(dataSource)
array = [DataSourceInfo]
print(assembler.assemble_document(input.ppt, output.ppt, array))
DataSource XML
<Product>
<Discount>0</Discount>
<ProductID>1</ProductID>
<ProductName>LG Nexus 5</ProductName>
<ProductPrice>350</ProductPrice>
<UnitsInStock>5</UnitsInStock>
<Barcode>123456789qwertyu0025</Barcode>
</Product>
- Set up the source document data path
- Set up the source document template path
- Set up destination report path
- Instantiate DocumentAssembler class
- Generate report
To learn more about library features, please refer to theadvanced usage section.
You may easily run the code above and see the feature in action in our GitHub examples:
Was this page helpful?
Any additional feedback you'd like to share with us?
Please tell us how we can improve this page.
Thank you for your feedback!
We value your opinion. Your feedback will help us improve our documentation.