<html>
<head>
<script type="text/javascript">
function validateFloat()
{
var o = document.frmInput.txtInput;
switch (isFloat(o.value))
{
case true:
alert(o.value + " is an float")
break;
case false:
alert(o.value + " is not an float")
}
}
</script>
</head>
<body>
<form name="frmInput">
Enter something: <input name="txtInput" size="4">
<input type="button" value="Validate" onclick="validateFloat()"></input>
</form>
</body>
</html>
Not working. pls help