function checkdecimalPoints(ID)
{
var strString = document.getElementById(ID).value;
var currIndex=strString.indexOf('.');
var lastIndex=strString.lastIndexOf('.');
if(currIndex!=lastIndex)
{
alert('More than one decimal points are not allowed.');
document.getElementById(ID).value='';
document.getElementById(ID).focus();
return false;
}
return true;
}