Hi,
I'm a new bie with asp.net,
i have some textbox need to validator with value min,max reading from table in database,
in Servervalidate, i wrote code as below, but it's not working
float a1=0;
float up1 = 0;
float low1 = 0;
int[] arrayA ={1,2,3,4,5,6,7,8,9,10,11,12,13};
int[] arrayUp = {1,2,3,4,5,6,7,8,9,10,11,12,13};
int [] arrayLow = {1,2,3,4,5,6,7,8,9,10,11,12,13};
try
{
low1 = float.Parse(txtlow1.Text);
}
catch { }
try
{ up1 = float.Parse(txtup1.Text); }
catch { }
try
{
a1 = float.Parse(txtrgtT.Text.Trim());
}
catch{}
if (a1 > up1 || a1 < low1)
{
cst1.ErrorMessage = "Nhap sai gia tri";
args ...
Go to the complete details ...