private void Page_Load(object sender,System.EventArgs e)
{
if(this.IsPostBack)return;
FarPoint.Web.Spread.Model.DefaultSheetStyleModel model=(FarPoint.Web.Spread.Model.DefaultSheetStyleModel)FpSpread1.Sheets[0].StyleModel;
FarPoint.Web.Spread.NamedStyle style=new FarPoint.Web.Spread.NamedStyle("Yellow");
style.BackColor=Color.Yellow;
FpSpread1.NamedStyles.Add(style);
FarPoint.Web.Spread.NamedStyle style1=new FarPoint.Web.Spread.NamedStyle("Red");
style1.BackColor=Color.Red;
FpSpread1.NamedStyles.Add(style1);
model.SetDirectName(0,0,"Yellow");
model.SetDirectName(0,2,"Red");
ListBox1.Items.Add(model.NamedStyles.Count.ToString());
}