DataTable tblMain = new DataTable();
int i;
tblMain = new DataTable();
tblMain.Columns.Add("ColA");
tblMain.Columns.Add("ColB");
for (i = 1; i <=99; i++)
{
DataRow r = tblMain.NewRow();
r[0] = "A " + i.ToString();
r[1] = "B " + i.ToString();
tblMain.Rows.Add(r);
}
FpSpread1.DataSource = tblMain;
FpSpread1.ActiveSheetView.AllowSort = true;
FarPoint.Web.Spread.Model.BaseSheetAxisModel b;
FarPoint.Web.Spread.Model.SortIndicator si;
b = (FarPoint.Web.Spread.Model.BaseSheetAxisModel)FpSpread1.ActiveSheetView.ColumnAxisModel;
b.SetSortIndicator(0, FarPoint.Web.Spread.Model.SortIndicator.Descending);
si = b.GetSortIndicator(0);
Response.Write(si.ToString());