This is the code:
try entering 198.45
it gives 198, is there a way to make it show 199.
in my example i have given just 2 decimal places actually it can also be like this:
198.445
198.4565455
i just want to round it off to the nearest integer...
Known is handfull, Unknown is worldfull
Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Untitled Document</title>
<script>
function Round(TheValue,ThePoints)
{
TheValue=Math.round(TheValue)
document.getElementById("RoundDiv").innerHTML=TheValue
}
</script>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<input type="text" name="t1" onChange="Round(this.value)">
<div id="RoundDiv"></div>
</body>
</html>
try entering 198.45
it gives 198, is there a way to make it show 199.
in my example i have given just 2 decimal places actually it can also be like this:
198.445
198.4565455
i just want to round it off to the nearest integer...
Known is handfull, Unknown is worldfull