Products Technologies Demo Docs Blog Support Company

Reporting: Merge Blocks Rendered As Numbered Lists

Merge blocks can render numbered lists from data sources by placing merge fields inside list items and converting the selection to a merge block. The template requires a blank trailing list item for row repetition, and multiple lists need Restart Numbering set via the dialog.

Reporting: Merge Blocks Rendered As Numbered Lists

A merge block repeats the content based on the number of data rows or instances in an IEnumerable object. Typically, a merge block is a table row or a table. But a merge block is also perfect to create numbered lists based on database content.

Consider the following template that should list all products followed by all customers:

Reporting: Merge blocks rendered as numbered lists

As you can see in the template, there is a blank list item under each numbered list. This is required, so that the next item from the data source is also added as a numbered list item.

In order to insert such a repeating block, follow these steps:

  1. Insert your desired merge field into a new line.

  2. Then select the paragraph and convert the selection into a numbered list using the Number Format button from the Paragraph ribbon group:

    Reporting: Merge blocks rendered as numbered lists
  3. Set the input position after the field and press ENTER to insert a new line:

    Reporting: Merge blocks rendered as numbered lists
  4. Select the block from the new blank list item position to the beginning of the inserted merge field. If you enable the control characters (¶), the carriage return after the first list item should be part of the selection:

    Reporting: Merge blocks rendered as numbered lists
  5. Now, this selection can be converted to a merge block by choosing the desired block name from the Merge Block drop-down in the Reports ribbon tab.

    Reporting: Merge blocks rendered as numbered lists

When inserting a second list, make sure that this list is set to Restart Numbering using the Bullets and Numbering dialog:

Reporting: Merge blocks rendered as numbered lists

Stay in the loop!

Subscribe to the newsletter to receive the latest updates.

Reporting

The Text Control Reporting Framework combines powerful reporting features with an easy-to-use, MS Word compatible word processor. Users can create documents and templates using ordinary Microsoft Word skills. The Reporting Framework is included in all .NET based TX Text Control products including ASP.NET, Windows Forms and WPF.

See Reporting products

Related Posts

ASP.NETReportingPDF

.NET C# PDF Generation Techniques: Which Method is Right for Your Project?

This article explains the distinct advantage TX Text Control offers with its true WYSIWYG (What You See Is What You Get) template system, where templates are designed visually, similar to…


ASP.NETReportingASP.NET Core

Best Practices for Mail Merge and Form Field Processing in ASP.NET Core C#…

This article provides best practices for mail merge and form field processing in ASP.NET Core C# applications using TX Text Control .NET Server. It shows how to use the Document Editor to create…


ASP.NETReportingASP.NET Core

Advantages of Flow Type Layout Reporting vs. Banded Reporting or PDF…

This article shows the advantages of flow type layout reporting compared to banded reporting or populating PDF placeholders in .NET C#. It explains the differences and the benefits of using a flow…


ActiveXASP.NETReporting

TX Text Control 32.0 Has Been Released

We are pleased to announce the immediate availability of TX Text Control 32.0 for all platforms including ASP.NET, Windows Forms, WPF and ActiveX.


AngularJavaScriptReporting

Getting Started: Angular Document Editor Attributes Explained

This article explains the possible attributes that can be used when initializing the TX Text Control Document Editor for Angular.

Share on this blog post on: