Spread ASP.NET 6.0 Product Documentation
SortIndicator Property
See Also  Example Send Feedback
FarPoint.Web.Spread Assembly > FarPoint.Web.Spread Namespace > Column Class : SortIndicator Property


Glossary Item Box

Gets or sets the sort indicator for this column.

Syntax

Visual Basic (Declaration) 
Public Property SortIndicator As SortIndicator
Visual Basic (Usage)Copy Code
Dim instance As Column
Dim value As SortIndicator
 
instance.SortIndicator = value
 
value = instance.SortIndicator
C# 
public SortIndicator SortIndicator {get; set;}

Property Value

SortIndicator setting

Remarks

The sort indicator appears after the data is sorted and appears only in the column by which the data is sorted.

Example

This example creates a Column object for the default active spreadsheet, sets text in the first three rows of the column and in a button click event sorts the data in the column. The sort indicator for the column is displayed after the column is sorted.
C#Copy Code
privatevoidPage_Load(objectsender,System.EventArgse)
{
if(this.IsPostBack)return;

FarPoint.Web.Spread.Columnmycol;
mycol=FpSpread1.ActiveSheetView.Columns[1];
FpSpread1.ActiveSheetView.SetValue(0,1,"Alignment");
FpSpread1.ActiveSheetView.SetValue(1,1,"CarbAdjust");
FpSpread1.ActiveSheetView.SetValue(2,1,"Brakes");
mycol.SortIndicator=FarPoint.Web.Spread.Model.SortIndicator.Descending;
}

privatevoidButton1_Click(objectsender,System.EventArgse)
{
FpSpread1.ActiveSheetView.SortRows(1,true,true);
}
Visual BasicCopy Code
PrivateSubPage_Load(ByValsenderAsSystem.Object,ByValeAsSystem.EventArgs)HandlesMyBase.Load

If(Me.IsPostBack)ThenReturn

DimmycolAsFarPoint.Web.Spread.Column
mycol=FpSpread1.ActiveSheetView.Columns(1)
FpSpread1.ActiveSheetView.SetValue(0,1,"Alignment")
FpSpread1.ActiveSheetView.SetValue(1,1,"CarbAdjust")
FpSpread1.ActiveSheetView.SetValue(2,1,"Brakes")
mycol.SortIndicator=FarPoint.Web.Spread.Model.SortIndicator.Descending

EndSub

PrivateSubButton1_Click(ByValsenderAsSystem.Object,ByValeAsSystem.EventArgs)HandlesButton1.Click
FpSpread1.ActiveSheetView.SortRows(1,True,True)
EndSub

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

© 2002-2012 GrapeCity, Inc. All Rights Reserved.