| Visual Basic (Declaration) | |
|---|---|
Public Class TableView Inherits UIViewBase Implements ISupportInitialize, IFrameworkInputElement, IInputElement, IAnimatable | |
| C# | |
|---|---|
public class TableView : UIViewBase, ISupportInitialize, IFrameworkInputElement, IInputElement, IAnimatable | |
| XAML | Copy Code |
|---|---|
<Grid xmlns:xcdg="http://schemas.xceed.com/wpf/xaml/datagrid"> | |
| XAML | Copy Code |
|---|---|
<Grid xmlns:xcdg="http://schemas.xceed.com/wpf/xaml/datagrid"> | |
| XAML | Copy Code |
|---|---|
<Grid xmlns:xcdg="http://schemas.xceed.com/wpf/xaml/datagrid" | |
The View property of the DataGridControl class determines which view is applied to a grid. If the View property is left to its default value, null (Nothing in Visual Basic), or explicitly set to null, the default table-view layout will be used with the system color scheme. The Theme property of the View class can be set to change the color scheme applied to a grid's elements. If left to its default value, null, the system color scheme will be used. In either case, if the system-color theme is not recognized (e.g., a third-party color scheme is being used), the Aero normal-color theme will be used.
Fixed Columns vs. Templates
In order to support fixed columns when creating a new row template for a table-view layout, the following criteria must be met:
- The PART_CellsHost template part must be a FixedCellPanel.
- The FixedCellCount property of the FixedCellPanel must be bound to the table view's FixedColumnCount property using a TwoWay ViewBinding.
The fixed-cell-panel properties listed below are also usually bound when provided a new row template for a table-view layout:
- SplitterStyle (TemplateBinding xcdg:TableView.FixedColumnSplitterStyle)
- SplitterWidth (xcdg:ViewBinding FixedColumnSplitterWidth)
- ShowSplitter (xcdg:ViewBinding ShowFixedColumnSplitter)
- FixedColumnDropMarkPen (xcdg:ViewBinding FixedColumnDropMarkPen)
If a new template is provided for a DataGridControl and fixed columns are to be supported, it is essential that a TableViewScrollViewer be used. This scroll viewer is responsible for preserving the TranslateTransforms that fix and scroll elements, as well as executing the PageLeft and PageRight actions according to the reduced viewport. It is also recommended that an AdornerDecorator be located above the TableViewScrollViewer of the templated DataGridControl to support drag and dropping of the fixed-column splitter correctly.
System.Object
System.Windows.Threading.DispatcherObject
System.Windows.DependencyObject
System.Windows.ContentElement
System.Windows.FrameworkContentElement
Xceed.Wpf.DataGrid.Views.ViewBase
Xceed.Wpf.DataGrid.Views.UIViewBase
Xceed.Wpf.DataGrid.Views.TableView
Supported Operating Systems: Windows Server 2003 Service Pack 1; Windows Vista; Windows XP Service Pack 2
Reference
TableView MembersXceed.Wpf.DataGrid.Views Namespace
Basic Concepts
Views and ThemesTable View



Copy Code