In-Paragraph List in HTML Document
Leave feedback
NoteIn this article, we will use GroupDocs.Assembly to generate a In-Paragraph List report in HTML Document format.
As a report developer, you are required to describe the services you are providing with the following key requirements:
- A descriptive or informative line like “We provide support for the following products:”.
- Show all the products along with the above sentence.
- Report must be generated in the HTML Document.
We provide support for the following products: <<foreach [in products]>>
<<[indexOf() != 0 ? ", " : ""]>><<[ProductName]>><</foreach>>
TipFor detailed technical information about syntax, expressions and report generation by the engine, please visit: Working with GroupDocs.Assembly Engine.
Please download the sample Common List document we created in this article:
NoteThe example reads the shop data described in The Business Layer.
import json
from groupdocs.assembly import DataSourceInfo, DocumentAssembler
with open("products.json", encoding="utf-8") as f:
products = json.load(f)
assembler = DocumentAssembler()
assembler.assemble_document("in-paragraph-list.html", "in-paragraph-list-report.html", DataSourceInfo(products, "products"))
The following sample file is used in this example: in-paragraph-list.html
The following sample file is used in this example: products.json
<html>
<body>
We provide support for the following products: Harbor Blend whole bean coffee, Lighthouse Espresso beans, Aged harbour cheddar, Chestnut honey, Oat and honey biscuits, Cold-pressed olive oil, Smoked sea salt, Smoked gouda, Autumn Harvest apple butter, Autumn Harvest spiced roast
</body>
</html>
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.