<asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ControlToValidate="TextBox1" ErrorMessage="RegularExpressionValidator" ValidationExpression="\d{5}">Enter 5 digits</asp:RegularExpressionValidator>
protected void Page_Load(object sender, EventArgs e)
{
FpSpread1.NonEditModeValidation = true;
FarPoint.Web.Spread.TextCellType tcell1 = new FarPoint.Web.Spread.TextCellType();
tcell1.Validators.Add(RegularExpressionValidator1);
FpSpread1.ActiveSheetView.Columns[1].CellType = tcell1;
FpSpread1.ActiveSheetView.Columns[1].BackColor = System.Drawing.Color.AliceBlue;
FpSpread1.ValidationErrorMessage = "test";
}