
//this function use to display cat product using on chnage 
function check_numeric_value(getValue) {

	getValue = document.getElementById(getValue);
	if(numValue(getValue)== false) return false;

}

function check_return_rate() {

	present_value = document.getElementById("present_value");
	if(blankValidation(present_value,"Present value cannot be blank.")== false) return false;

	future_value = document.getElementById("future_value");
	if(blankValidation(future_value,"Future value cannot be blank.")== false) return false;

	years = document.getElementById("years");
	if(blankValidation(years,"Year value cannot be blank.")== false) return false;

}

function doCalc()
{
	zeroBlanks(document.mainform);
	var pv = numval(document.mainform.pv.value);
	var fv = numval(document.mainform.fv.value);
	var y = numval(document.mainform.y.value);

	document.mainform.r.value = formatNumber(returnRate(pv,fv,y)*100,2);
}
