The grid control displays data using Views. You can think of a View as a visual component incorporated into the grid control which:
• presents data from a data source to an end-user
• provides the means to edit data
• contains multiple edit, customization and behavior options, etc
You can use one of the following Views to display data: Grid View, Layout View, Banded Grid View, Advanced Banded Grid View or Card View. Or, you can create a custom View if the standard Views do not suit your particular needs.
XtraGrid supports master-detail data representation. Master and detail tables are presented using independent Views. For instance, you can display the master table in a Grid View while displaying detail tables using card Views. The hierarchical structure of Views reflects master-detail relationships between the tables in the data source.
To access the View displayed at the top hierarchy level, use the GridControl.MainView property. This View represents the table referenced by the GridControl.DataSource and GridControl.DataMember properties. When the grid control is created, its GridControl.MainView property already refers to an instance of the GridView class, i.e. the top level data table will be represented using a Grid View.
The GridControl.LevelTree property allows you to specify pattern Views for representing particular master-detail relationships. These Views are never displayed onscreen. They only provide settings for creating real detail Views (clones) that appear when master rows are expanded.
The XtraGrid provides a number of ways to customize its look and feel. The GridControl.LookAndFeel property allows you to control the overall look and feel of the grid (how headers, scrollbars, borders, buttons and other elements are painted). By default, all the Views use these look and feel settings. It's also possible to specify look and feel settings for individual Views. This can be done via a View's BaseView.PaintStyleName property.
The Appearance technology allows the styles of particular visual elements in a View to be controlled. Each View has an BaseView.Appearance property which contains multiple style properties that correspond to all the available visual elements. You can specify the element's foreground, background colors, font settings, gradient mode, text options, etc.
The XtraGrid also provides various predefined painting schemes which facilitate customizing the grid.
Skins is another way to bring a unique and unconventional look and feel to the control.
XtraGrid provides the Level Designer and XtraGrid Designer to customize the control and Views at design time.
The Level Designer shows the hierarchical structure of Views representing master-detail relationships. It helps you access and change the main View and pattern Views, and create new levels("relation name - pattern view" associations). The latter can be useful if you wish to implement master-detail relationships via code, but create and customize pattern Views at design time.
You can select a View in the Level Designer to access its settings via the Properties window. If a pattern View is selected, the grid displays it as if it were the main View. If you need to access a column's settings at design time, you can simply click its header right on the form. This displays the column settings in the Properties window.
For a Grid View or its descendant, you can customize the layout right on the form, using only mouse operations.
Some tasks (such as creating columns and bands, accessing columns in a card view, applying grid formats, etc) can only be performed via the grid's designer. The XtraGrid Designer allows you to manage levels, Views, bands, columns, summaries, column editors (repository items), style settings and printing options.
➤ Dev Components ➤ DevExpress Controls for WinForms ➤ DevExpress XtraGrid
Source of Information : 1998-2010 Developer Express Inc Help