<ig:XamGrid x:Name="dataGrid" ItemsSource="{Binding Path=Customers}" CellControlGenerationMode="Recycle" />
Please note that this control has been retired and is now obsolete to the XamDataGrid control, and as such, we recommend migrating to that control. It will not be receiving any new features, bug fixes, or support going forward. For help or questions on migrating your codebase to the XamDataGrid, please contact support.
This topic describes how the horizontal scrolling can be improved if many columns are displayed in the xamGrid™ control.
The following topic is a prerequisite to understanding this topic:
This topic contains the following sections:
It is essential for the virtualization process that the visual elements are only created when they are in view in the xamGrid control.
By default, a CellControl instance is created when a cell comes into view and this instance is used only for this particular cell and it is never recycled. The same behavior is achieved if the CellControlGenerationMode
is set to Virtualize
.
If the CellControlGenerationMode
is set to Recycle
, the CellControl
instances are recycled and reused by the cells in the same row when a horizontal scrolling is performed.
The following table maps the desired configuration to the property settings that manage it.
Following is the code that implements this example.
In XAML:
<ig:XamGrid x:Name="dataGrid" ItemsSource="{Binding Path=Customers}" CellControlGenerationMode="Recycle" />
The following topics provide additional information related to this topic.