'宣言 Public Property RowSelectorHeaderStyle As Infragistics.Win.UltraWinGrid.RowSelectorHeaderStyle
public Infragistics.Win.UltraWinGrid.RowSelectorHeaderStyle RowSelectorHeaderStyle {get; set;}
RowSelectorHeaderStyleは、行セレクターが表示される場合に、行セレクターの上の領域の外観と配置を決定します。
RowSelectorHeaderStyle を None に設定すると、この領域に表示要素は割り当てられず、最初の列のヘッダーは列の左端に並びます。
RowSelectorHeaderStyle が ExtendFirstColumn に設定されると、最初の列のヘッダーが左に拡張して行セレクターの上の領域を占めます。
RowSelectorHeaderStyle が SeparateElement に設定されると、行セレクターの上に RowSelectorHeaderUIElement が配置され、最初の列のヘッダーは列の左端に並びます。
デフォルト値はExtendFirstColumnです。
RowSelectorHeaderStyle を SeparateElement に設定した場合は、RowSelectorHeaderAppearance オブジェクトを使用して RowSelectorHeader の外観を設定できます。
Imports Infragistics.Shared Imports Infragistics.Win Imports Infragistics.Win.UltraWinGrid Private Sub button_Click(sender As Object, e As System.EventArgs) ' The RowSelectorHeaderStyle determines the look and position of the area above Row Selectors ' if Row Selectors are visible. ' If the RowSelectorHeaderStyle is set to None there will be no visible element assigned to ' this area and the first header will be aligned with the left edge of the column. Me.ultraGrid1.DisplayLayout.Override.RowSelectorHeaderStyle = RowSelectorHeaderStyle.None ' If the RowSelectorHeaderStyle is set to ExtendFirstColumn the first header will extend to ' the left over the area above the Row Selectors. The Default value is ExtendFirstColumn. Me.ultraGrid1.DisplayLayout.Override.RowSelectorHeaderStyle = RowSelectorHeaderStyle.ExtendFirstColumn ' If the RowSelectorHeaderStyle is set to SeperateElement a RowSelectorHeaderUIElement will be ' positioned above the Row Selectors and the first header will be aligned with the left edge of ' the column. Me.ultraGrid1.DisplayLayout.Override.RowSelectorHeaderStyle = RowSelectorHeaderStyle.SeperateElement ' If the RowSelectorHeaderStyle is set to SeperateElement the RowSelectorHeaderAppearance object ' can be used to set the appearance of the RowSelectorHeader. ' Set the RowSelectorHeaderAppearance on the layout's override. Me.ultraGrid1.DisplayLayout.Override.RowSelectorHeaderAppearance.BackColor = Color.LightGreen ' You can override the grid-wide setting for a particular band by setting the override ' of the particular band. Me.ultraGrid1.DisplayLayout.Bands(1).Override.RowSelectorHeaderStyle = RowSelectorHeaderStyle.None End Sub 'button_Click
using Infragistics.Shared; using Infragistics.Win; using Infragistics.Win.UltraWinGrid; private void button_Click(object sender, System.EventArgs e) { // The RowSelectorHeaderStyle determines the look and position of the area above Row Selectors // if Row Selectors are visible. // If the RowSelectorHeaderStyle is set to None there will be no visible element assigned to // this area and the first header will be aligned with the left edge of the column. this.ultraGrid1.DisplayLayout.Override.RowSelectorHeaderStyle = RowSelectorHeaderStyle.None; // If the RowSelectorHeaderStyle is set to ExtendFirstColumn the first header will extend to // the left over the area above the Row Selectors. The Default value is ExtendFirstColumn. this.ultraGrid1.DisplayLayout.Override.RowSelectorHeaderStyle = RowSelectorHeaderStyle.ExtendFirstColumn; // If the RowSelectorHeaderStyle is set to SeperateElement a RowSelectorHeaderUIElement will be // positioned above the Row Selectors and the first header will be aligned with the left edge of // the column. this.ultraGrid1.DisplayLayout.Override.RowSelectorHeaderStyle = RowSelectorHeaderStyle.SeperateElement; // If the RowSelectorHeaderStyle is set to SeperateElement the RowSelectorHeaderAppearance object // can be used to set the appearance of the RowSelectorHeader. // Set the RowSelectorHeaderAppearance on the layout's override. this.ultraGrid1.DisplayLayout.Override.RowSelectorHeaderAppearance.BackColor = Color.LightGreen; // You can override the grid-wide setting for a particular band by setting the override // of the particular band. this.ultraGrid1.DisplayLayout.Bands[1].Override.RowSelectorHeaderStyle = RowSelectorHeaderStyle.None; }