The following code works in IE, but Netscape goes into a loop. I just
want to test if an entry is numeric. If not, put the focus back on the
field for correction (and select it for user convenience). Netscape gives
my alert, and when I press OK to clear the alert, it flashes back to the
field and then gives the alert again.
Thanks for your help!
Phil
function checkNumeric(inputObject)
{
if (inputObject.value == "")
{
return true;
}
if (isNaN(inputObject.value))
{
inputObject.focus();
inputObject.select();
alert ("This entry must be a number!!");
return false;
}
else
{
insertCommas (inputObject);
adjustRight(inputObject,22);
return true;
}
}