Linq reporting engine - How to insert page breaks

can i get access to code base, i have similar issue

@Sangamesh019 Here are the documents: Docs.zip (17.6 KB)

extra page added with it. how to resolve?

@Sangamesh019 You can use Page Break Before paragraph option:

For example see the attached modified template:
in.docx (12.0 KB)
out.docx (9.3 KB)

test code:

List<string> items = new List<string>() { "First", "Second", "Third" };
                       
Document doc = new Document(@"C:\Temp\in.docx");
ReportingEngine engine = new ReportingEngine();
engine.BuildReport(doc, items, "items");
doc.Save(@"C:\Temp\out.docx");

Yes, i am able to achieve it from word page break and as well from ASPOSE ControlChar.PAGE_BREAK feature as well

1 Like