Spread WPF Documentation
Top10Condition Constructor
Example 


GrapeCity.Windows.SpreadSheet.Data Namespace > Top10Condition Class : Top10Condition Constructor
Creates a new top 10 condition.
Syntax
'Declaration
 
Public Function New()
'Usage
 
Dim instance As New Top10Condition()
public Top10Condition()
Example
This example filters data.
for (var row = 0; row < 25; row++)
{
     GcSpreadSheet1.Sheets[0].SetValue(row, 0, row);
}
var rowFilter = new GrapeCity.Windows.SpreadSheet.Data.HideRowFilter(new GrapeCity.Windows.SpreadSheet.Data.CellRange(0, 0, 25, 1));
GcSpreadSheet1.Sheets[0].RowFilter = rowFilter;
var top10Con = new GrapeCity.Windows.SpreadSheet.Data.Top10Condition();
top10Con.Type = GrapeCity.Windows.SpreadSheet.Data.Top10ConditionType.Top;
top10Con.ExpectedValue = 10;
var filter = GcSpreadSheet1.Sheets[0].RowFilter;
filter.AddFilterItem(0, top10Con);
filter.Filter(0);
For row As Integer = 0 To 25
    GcSpreadSheet1.Sheets(0).SetValue(row, 0, row)
Next

Dim rowFilter As New GrapeCity.Windows.SpreadSheet.Data.HideRowFilter(New GrapeCity.Windows.SpreadSheet.Data.CellRange(0, 0, 25, 1))
GcSpreadSheet1.Sheets(0).RowFilter = rowFilter
Dim top10Con As New GrapeCity.Windows.SpreadSheet.Data.Top10Condition()
top10Con.Type = GrapeCity.Windows.SpreadSheet.Data.Top10ConditionType.Top
top10Con.ExpectedValue = 10
Dim filter = GcSpreadSheet1.Sheets(0).RowFilter()
filter.AddFilterItem(0, top10Con)
filter.Filter(0)
See Also

Reference

Top10Condition Class
Top10Condition Members