I am using a custom validator on a web form. I am using the following code:
private void CheckRom()
{
int to = int.Parse(romToText.Text);
int from = int.Parse(romFromText.Text);
if (romCheck.Checked == true && romFromText.Text != null && romToText !=
null)
{
if (to < from)
{
validateROM.ErrorMessage = "The TO amount must be Greater than the
FROM amount!";
validateROM.IsValid = true;
}
else
{
validateROM.IsValid = false;
}
}
However, when running the code, the validator never fires. Can anyone help
with the code to make this happen?
Thanks,
Dave
--
Message posted via http://www.dotnetmonster.com