C1.Win.C1FlexGrid Namespace > RowCollection Class : Selected Property |
'Declaration
<BrowsableAttribute(False)> <DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Hidden)> Public ReadOnly Property Selected As RowCollection
'Usage
Dim instance As RowCollection Dim value As RowCollection value = instance.Selected
[Browsable(false)] [DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)] public RowCollection Selected {get;}
[Browsable(false)] [DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)] public: property RowCollection^ Selected { RowCollection^ get(); }
The code below removes all selected rows from the grid.
Note that foreach loops can't be used to modify the collections being iterated over. This example works because the Selected collection is being enumerated while the Rows collection is being modified.
// delete all selected rows foreach (Row r in _flex.Rows.Selected) { _flex.Rows.Remove(r); }
Target Platforms: 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