Control : MultiColumnList

Back to Controls

The MultiColumnList control displays fields on a collection of objects.

 

Contents

Overview

Use the MultiColumnList control to display a collection of objects in a series of columns. You can also enable in-line editing of data within the MultiColumnList control.

Capabilities

You can use the MultiColumnList control to:

  • Display the fields on a collection in a series of columns (Example 1).
  • Add and remove data from a collection (Example 2).
  • Edit the collection's data (Example 3).
  • Display a form. (Example 4).

Limitations

 

Requirements

 

Examples

The following examples are intended to be used with sample code that you can import into your Bungee Builder workspace from the Start Page. Each example is intended to build upon a previous example to provide you with a complete understanding of how to use this control.

Example 1: Binding to a Collection (Ex1_PersonList)

This example shows you how to bind a MultiColumnList control to a collection.

The MultiColumnList control is bound to the collection people, which is of type Person. The Person class contains the fields address, birth, firstName, and lastName. The fields are all mapped to headings on the MultiColumnList control (the field address is a complex type that is formatted as part of the column property definition).

Example 2: Binding to a Collection (Ex2_EditPersonList)

This example shows you how to add support for editing a field within the MultiColumnList control.

Two buttons (Add New and Remove) are added to the form from Example 1. These buttons add and remove data from the underlying collection. In addition, Double Click and Remove function adapters (Adapter tab) are implemented. The Double Click function adapter lets you double-click an item in the MultiColumnList control and display an editing window. The Remove function adapter lets you select an item and press the Delete key to remove it from the collection.

Example 3: Binding to a Collection (Ex3_InlineEditPersonList)

This example shows you how to enable inline editing of a field within the MultiColumnList control.

Inline editing for the Last Name and First Name columns has been added to the form from Example 1. Inline editing is enabled by setting the Edit Type property on a column (General tab, Column Settings property, on the selected column, General tab, Edit Type). For this example, Edit Type has been set to Read/Write for Last Name and First Name and Edit Type has been set to WriteOnly for Birth.

Example 4: Embedding a Form (Ex4_Embedded_Form)

This example shows you how to embed a form within a MultiColumnList control. 

A read-only form (ReadOnly) was added to the Address class. This form is used to display the city and state information within the MultiColumnList control (the form is repeated for each record). The form is assigned under the Object Edit tab in the Edit Columns dialog box (set Object Read Only Form to the desired read-only form, and optionally, set Object Write Only Form to the desired write-only form). 

This example also demonstrates shading for alternate rows. The property is located on the StyleSheet for the the MultiColumnList control (MultiColumnListStyle). For Cell Background Type, select Alternating.

Example Helper Classes

Address

This class defines the address fields (city and state) used to hold the city and state information for the addresses in all four examples. It also contains a detail form for displaying the city and state. 

Person

This class defines the fields used to describe a person (address, birth, firstName, and lastName). It also contains a detail form for displaying the name, address, and birth date of a person.

Reference 

Supported Types (Control Adapter)

Type Summary
Collection<Object>

Complex Object type fields within application objects that are connected to the MultiColumnList control where the field is a collection (the field's Is Collection property is set to true). For each item in the field’s collection, a corresponding row in the MultiColumnList is displayed by configuring the columns you want and extracting key attributes from the object’s fields to use as items in each column of the row. For example, if an object in the collection is of type Person with firstName, lastName, birth, and address fields, you can define how many columns you would like and how to extract those fields from the object when computing the text for each column of the MultiColumnList row that represents that object. If the collection changes, including the internal members of the object used in text calculation, the MultiColumnList view auto-tracks those changes and updates the MultiColumnList control on the remote client appropriately.

Collections of type Object include any subclass of Object as well. For example, Collection<Person> can be tied to the MultiColumnList, where Person subclasses from Object and represents any model object in your project. 

Associated Properties

Common Properties Index

Specialized Properties

Unique Properties

 


Log in if you would like to rate this page.
    Copyright © 2005 - 2007 Bungee Labs. All rights reserved.