'宣言 Public Property RowFilterAction As RowFilterAction
public RowFilterAction RowFilterAction {get; set;}
RowFilterAction は、フィルターによって除外された行に対して実行するアクションを指定します。AppearancesOnly の場合は、フィルターによって除外された行が表示されたままになります。DisableFilteredOutRows の場合は、フィルターによって除外された行が表示されたままになりますが、ユーザーがその内容を変更できないように無効になります。HideFilteredOutRows の場合は、フィルターによって除外された行が非表示になります。
アクティブな行フィルターが存在する場合は、フィルターによって除外された行とそのセルにFilteredOutRowAppearanceとFilteredOutCellAppearanceが適用され、フィルター条件に一致する行とそのセルにFilteredInRowAppearanceとFilteredInCellAppearanceが適用されます。
Imports Infragistics.Shared Imports Infragistics.Win Imports Infragistics.Win.UltraWinGrid Private Sub UltraGrid1_InitializeLayout(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles UltraGrid1.InitializeLayout ' Turn on row filtering functionality. e.Layout.Override.AllowRowFiltering = DefaultableBoolean.True ' Specifies whether to filter all rows in band or the sibling rows. e.Layout.Override.RowFilterMode = RowFilterMode.AllRowsInBand ' The action to take on rows that fail the filter criteria. e.Layout.Override.RowFilterAction = RowFilterAction.AppearancesOnly ' Setup various appearances that will be applied to rows that ' are filtered in (ones that pass the filter criteria). e.Layout.Override.FilteredInRowAppearance.BackColor = Color.Blue e.Layout.Override.FilteredInCellAppearance.ForeColor = Color.Yellow ' Setup various appearances that will be applied to rows that ' are filtered out (ones that fail the filter criteria). e.Layout.Override.FilteredOutRowAppearance.BackColor = SystemColors.ControlLight e.Layout.Override.FilteredOutCellAppearance.ForeColor = SystemColors.ControlDarkDark End Sub
using Infragistics.Shared; using Infragistics.Win; using Infragistics.Win.UltraWinGrid; using System.Diagnostics; private void ultraGrid1_InitializeLayout(object sender, Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs e) { // Turn on row filtering functionality. e.Layout.Override.AllowRowFiltering = DefaultableBoolean.True; // Specifies whether to filter all rows in band or the sibling rows. e.Layout.Override.RowFilterMode = RowFilterMode.AllRowsInBand; // The action to take on rows that fail the filter criteria. e.Layout.Override.RowFilterAction = RowFilterAction.AppearancesOnly; // Setup various appearances that will be applied to rows that // are filtered in (ones that pass the filter criteria). e.Layout.Override.FilteredInRowAppearance.BackColor = Color.Blue; e.Layout.Override.FilteredInCellAppearance.ForeColor = Color.Yellow; // Setup various appearances that will be applied to rows that // are filtered out (ones that fail the filter criteria). e.Layout.Override.FilteredOutRowAppearance.BackColor = SystemColors.ControlLight; e.Layout.Override.FilteredOutCellAppearance.ForeColor = SystemColors.ControlDarkDark; }