[Expand]General Information
[Expand]WinForms Controls
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Report and Dashboard Server
[Collapse]eXpressApp Framework
 [Expand]Getting Started
  [Expand]Application Solution Components
   Client-Side Mobile Application
  [Expand]Business Model Design
  [Expand]Application Model
  [Collapse]UI Construction
    UI Element Overview
    Windows and Frames
    Action Containers
     Ways to Show a View
     List View Column Generation
     List View Columns Customization
     List View Bands Layout
     List View Edit Modes
    [Expand]List View Data Access Modes Overview
     Display Properties of a Referenced Object in the Master Object's View
   [Expand]View Items
    List Editors
    Add and Override Images
    Text Notifications
    Ways to Show a Confirmation Dialog
    ASP.NET Web Application Appearance
    Application Personalization
    Using a Custom Control that is not Integrated by Default
    XAF Mobile Wrappers for DevExtreme Widgets
  [Expand]Extend Functionality
  [Expand]Data Manipulation and Business Logic
  [Expand]Security System
  [Expand]System Module
  [Expand]Extra Modules
  [Expand]Debugging, Testing and Error Handling
  [Expand]Application Life Cycle
 [Expand]Design-Time Features
 [Expand]Task-Based Help
  Frequently Asked Questions (FAQ)
 [Expand]API Reference
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation
This documentation page describes implementations made in our v17.2 release cycle. To learn about functionality shipping with v18.1, navigate to our updated help file experience at docs.devexpress.com. Learn More


XAF automatically generates Views as a part of the UI and uses them to show objects. Views have access to a specified data store and allow end-users to browse and edit data. XAF uses three main types of Views: a Detail View, List View, and Dashboard View. These types are abstract UI-independent elements which are View class descendant instances. This topic discusses View types and ways to access and customize them, and contains the following sections:

Expanded Composite View and Object View

The CompositeView class specifies the Composite View, which consists of View Items. Composite Views store View Items in the CompositeView.Items collection. You can add, insert and delete items from this collection using the CompositeView.AddItem, CompositeView.InsertItem and CompositeView.RemoveItem methods.

XAF has two actual Composite View types - the DashboardView and DetailView. Although the ListView class also derives from the CompositeView, it does not support the View Items layout.

The ObjectView class (a CompositeView descendant) specifies the Object View. It has two sub-types - the DetailView and the ListView. The ObjectView and its descendants are directly bound to data - to a single data object, or an object collection.

Expanded Detail View

The DetailView class specifies the Detail View. A Detail View displays a particular business class object. You can access this object in code using the DetailView.CurrentObject property.

A Detail View uses platform-specific data-oriented Property Editors to display the current object's persistent properties and fields. Non-persistent data is displayed in View Items (for example, StaticText or StaticImage).

The Detail View has two Edit modes: Edit and View. WinForms applications display a Detail View in the Edit mode only, while ASP.NET and Mobile applications can use either mode and switch between them (see DetailView.ViewEditMode).

Expanded List View

The ListView class defines a List View. A List View displays a collection of objects of the same class, using a CollectionSourceBase class's descendant.

List Views are visualized using List Editors (see ListEditor). Before XAF displays a List View, it calls the View.CreateControls method to create the List Editor's grid control. The default grid controls are XtraGrid (Windows Forms applications), ASPxGridView (ASP.NET Web applications), and List (Mobile applications). The control shows object property values in columns generated for each property. You can edit these values directly in the List View as described in the List View Edit Modes topic.

While WinForms and ASP.NET applications display List Views as a grid, Mobile applications show List Views as a list of Rows. Rows allow you to display certain object's property values in one block. See the List View Column Generation topic for details.

XAF has a special List View type - the Lookup List View. The Lookup List View is displayed in Lookup Property Editors or pop-up windows and contains fewer columns than the ordinary List View. You can use an ordinary List View as a Lookup List View and vice versa. The How to: Detect a Lookup List View in Code topic demonstrates how to check whether the current View is a Lookup List View.

Expanded Dashboard View

The DashboardView class defines Dashboard Views. They are not bound to data directly and display several Views side-by-side in a single Frame. These Views are DashboardViewItem objects. The Application Model's DashboardView node allows you to specify the View using the IModelDashboardViewItem.View property. Dashboard Views can also display static text and static images (see StaticText and StaticImage).

Before XAF displays a Dashboard View, it calls the View.CreateControls method to create a nested Frame for each DashboardViewItem. These Frames show the DashboardViewItems' Views.

Dashboard Views are not supported in Mobile applications.

Expanded Customize Views

You can customize Views in your application, for example, change the editor's layout in a Detail View, or column's visibility in a List View, using one of the following approaches:

Expanded See Also

Is this topic helpful?​​​​​​​