Version

Cell Merging Overview (WebHierarchicalDataGrid)

Purpose

An introduction to Merging Cells using the WebHierarchicalDataGrid™ control feature.

Required background

Prerequisite materials to understanding this topic.

Topic Purpose

Demonstrates through code examples how to enable sorting in the WebHierarchicalDataGrid .

Demonstrates through code examples how to enable the Outlook GroupBy feature of the WebHierarchicalDataGrid .

Cell Merging Overview

Introduction

Cell merging enables you to sort or group data within the WebHierarchicalDataGrid and display that data with cells containing the same values merged into a single cell. The cells only appear merged; the grid structure is not affected by the use of this function. Cell merging works with both the sorting behavior and grouping settings of the WebHierarchicalDataGrid .

The following screens illustrate an unmerged display (Figure 1) and a merged display (Figure 2). As you can see the merged display below (Figure 2), has sorted the records, gathering those records with the same region and displaying region as a single merged cell with one instance of the cell’s data.

By default, Cell Merging is disabled. Refer to the topic, Enabling Cell Merging for information on enabling this feature.

Supported Cell Merging behaviors

Cell merging can be independently enabled or disabled for either sorting behavior or grouping settings. A detailed explanation of how cell merging impacts each of these follows.

Cell Merging on sorting

The following screen shot illustrates how the data of a sorted WebHierarchicalDataGrid appears with Cell Merging enabled.

A close inspection of Figure 3 - Examples of Sort with Cell Merging Enabled reveals the effects of using the WebHierarchicalDataGrid ’s sorting behavior with Cell Merging enabled. In the sorting example, the sort criteria is for records where Country = ‘USA’, as you can see records meeting these criteria appear clustered together at the top of the grid.

Overview page for Cell Merging 3 WHDG.png

Figure 3 - Examples of Sort with Cell Merging Enabled

Cell Merging on grouping

The following screen shot illustrates the effect of WebHierarchicalDataGrid ’s group setting with Cell Merging enabled.

As you can see the country column contains values representing different countries, in this case the UK and USA . When displayed, the records are grouped by country where the value within the country cells has the same values, as in this example records belonging to either the UK or the USA are visually merged with other records belonging to the same country. Additionally, note that a row appears before the grouped records identifying the item grouped, its value and a record count. In this case Country, UK and USA with 4 and 5 records respectively.

Overview page for Cell Merging 4 WHDG.png

Related Content

Topics

The following topics provide additional information related to this topic.

Samples

The following samples provide additional information related to this topic.

Sample Purpose

Demonstrates the WebHierarchicalDataGrid ’s capabilities using its sort behavior with Cell Merging enabled. .

Demonstrates the WebHierarchicalDataGrid ’s capabilities using its group setting with Cell Merging enabled.