Version

SelectTypeRow Property

Returns or sets a value that determines the row selection type.
Syntax
'Declaration
 
Public Property SelectTypeRow As SelectType
public SelectType SelectTypeRow {get; set;}
Remarks

This property is used to specify which selection type will be used for the rows in the band or the grid controlled by the specified override. You can choose to allow the user to have multiple rows selected, only one row at a time selected, or to disallow the selection of rows.

You can use the SelectTypeCol and SelectTypeCell properties to specify the way in which columns and cells may be selected.

Because you may want to enable different types of selection at different levels of a hierarchical record set, SelectTypeRow is a property of the UltraGridOverride object. This makes it easy to specify different selection options for each band by assigning each UltraGridBand object its own UltraGridOverride object. If a band does not have an override assigned to it, the control will use the override at the next higher level of the override hierarchy to determine the properties for that band. In other words, any band without an override will use its parent band's setting for SelectTypeRow, and the top-level band will use the grid's setting.

Example
Following code shows how to control row-selection in the UltraGrid.

Imports Infragistics.Shared
Imports Infragistics.Win
Imports Infragistics.Win.UltraWinGrid

  Private Sub Button48_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles button48.Click

      ' Set the SelectTypeRow to Single so only a single row can be selected at a
      ' time. Setting it on the layout's Override applies it to the whole grid.
      Me.UltraGrid1.DisplayLayout.Override.SelectTypeRow = SelectType.Single

      ' You can override the grid-wide setting (setting on the layout's Override) on a 
      ' particular band by setting the associated properties on that band's Override. 
      ' Following code sets the SelectTypeRow on the band 0 override to allow the user
      ' to select multiple rows that band.
      Me.UltraGrid1.DisplayLayout.Bands(0).Override.SelectTypeRow = SelectType.Extended

      ' You can set the MaxSelectedRows to limit the number of rows the user can select.
      Me.UltraGrid1.DisplayLayout.Bands(0).Override.MaxSelectedRows = 100

  End Sub
using Infragistics.Shared;
using Infragistics.Win;
using Infragistics.Win.UltraWinGrid;
using System.Diagnostics;

private void button48_Click(object sender, System.EventArgs e)
{

	// Set the SelectTypeRow to Single so only a single row can be selected at a
	// time. Setting it on the layout's Override applies it to the whole grid.
	this.ultraGrid1.DisplayLayout.Override.SelectTypeRow = SelectType.Single;

	// You can override the grid-wide setting (setting on the layout's Override) on a 
	// particular band by setting the associated properties on that band's Override. 
	// Following code sets the SelectTypeRow on the band 0 override to allow the user
	// to select multiple rows that band.
	this.ultraGrid1.DisplayLayout.Bands[0].Override.SelectTypeRow = SelectType.Extended;

	// You can set the MaxSelectedRows to limit the number of rows the user can select.
	this.ultraGrid1.DisplayLayout.Bands[0].Override.MaxSelectedRows = 100;

}
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also