代码下载:http://download.csdn.net/source/2508693
代码
using
System;
using Lazy.Validate;
public partial class LazyValidate : System.Web.UI.Page
{
protected void Page_Load( object sender, EventArgs e)
{
}
protected void Button1_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsNumber(TextBox1.Text.Trim()).ToString();
}
protected void Button2_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsNumberSign(TextBox1.Text.Trim()).ToString();
}
protected void Button3_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsDecimal(TextBox1.Text.Trim()).ToString();
}
protected void Button4_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsDecimalSign(TextBox1.Text.Trim()).ToString();
}
protected void Button5_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsHasCHZN(TextBox1.Text.Trim()).ToString();
}
protected void Button6_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsEmail(TextBox1.Text.Trim()).ToString();
}
protected void Button7_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsUrl(TextBox1.Text.Trim()).ToString();
}
protected void Button8_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsTel(TextBox1.Text.Trim()).ToString();
}
protected void Button9_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsQQ(TextBox1.Text.Trim()).ToString();
}
protected void Button10_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsIDCard(TextBox1.Text.Trim()).ToString();
}
protected void Button11_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsEnglish(TextBox1.Text.Trim()).ToString();
}
protected void Button12_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsTrimRow(TextBox1.Text.Trim()).ToString();
}
protected void Button13_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsMobile(TextBox1.Text.Trim()).ToString();
}
protected void Button14_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsDate(TextBox1.Text.Trim()).ToString();
}
}
using Lazy.Validate;
public partial class LazyValidate : System.Web.UI.Page
{
protected void Page_Load( object sender, EventArgs e)
{
}
protected void Button1_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsNumber(TextBox1.Text.Trim()).ToString();
}
protected void Button2_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsNumberSign(TextBox1.Text.Trim()).ToString();
}
protected void Button3_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsDecimal(TextBox1.Text.Trim()).ToString();
}
protected void Button4_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsDecimalSign(TextBox1.Text.Trim()).ToString();
}
protected void Button5_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsHasCHZN(TextBox1.Text.Trim()).ToString();
}
protected void Button6_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsEmail(TextBox1.Text.Trim()).ToString();
}
protected void Button7_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsUrl(TextBox1.Text.Trim()).ToString();
}
protected void Button8_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsTel(TextBox1.Text.Trim()).ToString();
}
protected void Button9_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsQQ(TextBox1.Text.Trim()).ToString();
}
protected void Button10_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsIDCard(TextBox1.Text.Trim()).ToString();
}
protected void Button11_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsEnglish(TextBox1.Text.Trim()).ToString();
}
protected void Button12_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsTrimRow(TextBox1.Text.Trim()).ToString();
}
protected void Button13_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsMobile(TextBox1.Text.Trim()).ToString();
}
protected void Button14_Click( object sender, EventArgs e)
{
Label1.Text = lazyValidater.IsDate(TextBox1.Text.Trim()).ToString();
}
}