您的位置:首页 > 其它

当月水电气简单计算器

2008-04-25 14:46 239 查看
body{
font-size:12px;
text-align: center;
}
td{font-size:12px;
}
.outtab
{
border-top-width: 1px;
border-right-width: 1px;
border-bottom-width: 1px;
border-left-width: 1px;
border-top-style: solid;
border-right-style: solid;
border-bottom-style: solid;
border-left-style: solid;
border-top-color: #CCCCCC;
border-right-color: #CCCCCC;
border-bottom-color: #CCCCCC;
border-left-color: #CCCCCC;
}
#main
{
border: 1px solid #CCCCCC;
width:600px;
height:200px;
text-align: left;
padding: 10px;
}
//数字型验证部分
// JavaScript Document

//控制输入的形式为数值
function CheckNum(thetxtNum)
{
var _value = thetxtNum.value;
var kc=window.event.keyCode;

if(kc==110 || kc==190)//如果是.
{
if(_value.length==0)//第一个不允许输入。
{
alert("不能以小数点开头!");
window.event.returnValue = false;
return;
}
if(_value.indexOf(".")>=0)//如果已经存在.
{
//window.event.keyCode=8;
alert("不能再次输入小数点!");
window.event.returnValue = false;
return;
}
}

//alert(kc);
if( (kc>=48 && kc<=57) || (kc>=96 && kc<=105) || kc==110 || kc==190)//如果是数字 或 .
{
window.event.returnValue = true;
return;
}
else if(kc==8)//如果是退格
{
thetxtNum.select();
thetxtNum.value="";
thetxtNum.focus();
window.event.returnValue = false;
return;
}
else if(kc==13)
{
window.event.keyCode=9;
window.event.returnValue = true;
return;
}
else if(kc==9 || kc==45 || kc==46 || kc==16 || kc==17 || kc==18 || kc==20 || (kc>=112 && kc<=123))
{
window.event.returnValue = true;
return;
}
else
{
//window.event.keyCode=8;
alert("请输入数字!");
thetxtNum.value=0;
window.event.returnValue = false;
return;
}
}

//保留小数点后一位
function Transfer(thetxtNum)
{
var _value= parseFloat(thetxtNum.value);
if(isNaN(_value))
{
return;
}
thetxtNum.value = _value.toFixed(2);
}
////数字型验证部分-----end

//输入日期年月
function writeyearmonth()
{
var myDate = new Date();
myDate.getFullYear(); //获取完整的年份(4位,1970-????)
myDate.getMonth();
var rqstr="";
rqstr=myDate.getFullYear() +"年"+myDate.getMonth() +"月";
document.write (rqstr);
}

writeyearmonth();

水:起度 止度 单价 附加

电:起度 止度 单价 附加

气:起度 止度 单价 附加

说明:输入各项后,在页面任意空白处点击鼠标,页面自动计算一次结果!

名称起度(吨/度/方)止度(吨/度/方)数量(吨/度/方)单价(元)附加金额(元)总金额(元)
writeyearmonth();合计(元)

<!--CTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dt-->




<meta http-equiv="Content-Type" content="text/html; charset=gb2312" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" /><style type="text/css" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">...








body{...}{


font-size:12px;


text-align: center;


}




td{...}{font-size:12px;


}


.outtab




{...}{


border-top-width: 1px;


border-right-width: 1px;


border-bottom-width: 1px;


border-left-width: 1px;


border-top-style: solid;


border-right-style: solid;


border-bottom-style: solid;


border-left-style: solid;


border-top-color: #CCCCCC;


border-right-color: #CCCCCC;


border-bottom-color: #CCCCCC;


border-left-color: #CCCCCC;


}


#main




{...}{


border: 1px solid #CCCCCC;


width:600px;


height:200px;


text-align: left;


padding: 10px;




}</style><script>...


//数字型验证部分


// JavaScript Document




//控制输入的形式为数值


function CheckNum(thetxtNum)




...{


var _value = thetxtNum.value;


var kc=window.event.keyCode;




if(kc==110 || kc==190)//如果是.




...{


if(_value.length==0)//第一个不允许输入。




...{


alert("不能以小数点开头!");


window.event.returnValue = false;


return;


}


if(_value.indexOf(".")>=0)//如果已经存在.




...{


//window.event.keyCode=8;


alert("不能再次输入小数点!");


window.event.returnValue = false;


return;


}


}




//alert(kc);


if( (kc>=48 && kc<=57) || (kc>=96 && kc<=105) || kc==110 || kc==190)//如果是数字 或 .




...{


window.event.returnValue = true;


return;


}


else if(kc==8)//如果是退格




...{


thetxtNum.select();


thetxtNum.value="";


thetxtNum.focus();


window.event.returnValue = false;


return;


}


else if(kc==13)




...{


window.event.keyCode=9;


window.event.returnValue = true;


return;


}


else if(kc==9 || kc==45 || kc==46 || kc==16 || kc==17 || kc==18 || kc==20 || (kc>=112 && kc<=123))




...{


window.event.returnValue = true;


return;


}


else




...{


//window.event.keyCode=8;


alert("请输入数字!");


thetxtNum.value=0;


window.event.returnValue = false;


return;


}


}




//保留小数点后一位


function Transfer(thetxtNum)




...{


var _value= parseFloat(thetxtNum.value);


if(isNaN(_value))




...{


return;


}


thetxtNum.value = _value.toFixed(2);


}


////数字型验证部分-----end




//输入日期年月


function writeyearmonth()




...{


var myDate = new Date();


myDate.getFullYear(); //获取完整的年份(4位,1970-????)


myDate.getMonth();


var rqstr="";


rqstr=myDate.getFullYear() +"年"+myDate.getMonth() +"月";


document.write (rqstr);


}


</script>


<div id="main" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">


<ul removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">




<li removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"><script>...writeyearmonth();</script></li>


<li removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">水:起度 <input onkeydown="CheckNum(this)" onblur="dosum()" style="WIDTH: 50px" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" name="s1" /> 止度 <input onkeydown="CheckNum(this)" onblur="dosum()" style="WIDTH: 50px" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" name="s2" /> 单价 <input onkeydown="CheckNum(this)" onblur="dosum()" style="WIDTH: 50px" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" name="s3" /> 附加 <input onkeydown="CheckNum(this)" onblur="dosum()" style="WIDTH: 50px" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" name="s4" /> <br removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" /></li>


<li removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">电:起度 <input onkeydown="CheckNum(this)" onblur="dosum()" style="WIDTH: 50px" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" name="d1" /> 止度 <input onkeydown="CheckNum(this)" onblur="dosum()" style="WIDTH: 50px" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" name="d2" /> 单价 <input onkeydown="CheckNum(this)" onblur="dosum()" style="WIDTH: 50px" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" name="d3" /> 附加 <input onkeydown="CheckNum(this)" onblur="dosum()" style="WIDTH: 50px" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" name="d4" /> <br removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" /></li>


<li removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">气:起度 <input onkeydown="CheckNum(this)" onblur="dosum()" style="WIDTH: 50px" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" name="q1" /> 止度 <input onkeydown="CheckNum(this)" onblur="dosum()" style="WIDTH: 50px" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" name="q2" /> 单价 <input onkeydown="CheckNum(this)" onblur="dosum()" style="WIDTH: 50px" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" name="q3" /> 附加 <input onkeydown="CheckNum(this)" onblur="dosum()" style="WIDTH: 50px" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" name="q4" /> <br removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" /></li>


<li removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">说明:输入各项后,在页面任意空白处点击鼠标,页面自动计算一次结果! </li>


</ul>


<table cellspacing="0" bordercolordark="#ffffff" cellpadding="0" width="646" align="left" bordercolorlight="#000000" border="1" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">


<tbody removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">


<tr removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">


<td align="center" width="90" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">名称</td>


<td align="center" width="90" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">起度(吨/度/方)</td>


<td align="center" width="90" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">止度(吨/度/方)</td>


<td align="center" width="90" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">数量(吨/度/方)</td>


<td align="center" width="90" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">单价(元)</td>


<td align="center" width="90" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">附加金额(元)</td>


<td align="center" width="90" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">总金额(元)</td>


</tr>


<tr removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">


<td align="center" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">水</td>


<td id="a1" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


<td id="a2" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


<td id="a3" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


<td id="a4" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


<td id="a5" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


<td id="a6" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


</tr>


<tr removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">


<td align="center" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">电</td>


<td id="b1" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


<td id="b2" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


<td id="b3" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


<td id="b4" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


<td id="b5" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


<td id="b6" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


</tr>


<tr removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">


<td align="center" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">气</td>


<td id="c1" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


<td id="c2" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


<td id="c3" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


<td id="c4" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


<td id="c5" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


<td id="c6" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


</tr>


<tr removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}">




<td align="left" colspan="6" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"><script>...writeyearmonth();</script>合计(元)</td>


<td id="hj" align="right" removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}"> </td>


</tr>


</tbody>


</table>


<br removechild="function MyRC(arg1){var self = this;if (self.removeAttribute)self.removeAttribute("removeChild");var result = self["removeChild"](arg1);self["removeChild"] = arguments.callee; /*Finally restore the Override Function*/if(arg1.clearAttributes)arg1.clearAttributes();if(arg1.onclick)arg1.onclick=null;if(arg1.onmousemove)arg1.onmousemove=null;if(arg1.onmouseover)arg1.onmouseover=null;if(arg1.ondblclick)arg1.ondblclick=null;if(arg1.onmouseenter)arg1.onmouseenter=null;if(arg1.onmouseleave)arg1.onmouseleave=null;return result;}" /></div>




<script>...


//计算输入结果到TD


function dosum()




...{


var sum1,sum2,sum3,sum4;


var sl1,sl2,sl3;


sum1=0;sum2=0;sum3=0;sum4=0;


sl1=0;sl2=0;sl3=0;


var s1,s2,s3,s4,d1,d2,d3,d4,q1,q2,q3,q4;


s1=parseFloat(document.all.s1.value);//取值


s2=parseFloat(document.all.s2.value);


s3=parseFloat(document.all.s3.value);


s4=parseFloat(document.all.s4.value);


d1=parseFloat(document.all.d1.value);


d2=parseFloat(document.all.d2.value);


d3=parseFloat(document.all.d3.value);


d4=parseFloat(document.all.d4.value);


q1=parseFloat(document.all.q1.value);


q2=parseFloat(document.all.q2.value);


q3=parseFloat(document.all.q3.value);


q4=parseFloat(document.all.q4.value);


sl1=(s2-s1);//数量


sl2=(d2-d1);


sl3=(q2-q1);


sum1=sl1*s3+s4;//金额


sum2=sl2*d3+d4;


sum3=sl3*q3+q4;


sum4=sum1+sum2+sum3;


//输入出对应TD


document.all.a1.innerHTML=s1;


document.all.a2.innerHTML=s2;


document.all.a3.innerHTML=sl1;


document.all.a4.innerHTML=s3;


document.all.a5.innerHTML=s4;


document.all.a6.innerHTML=sum1;




document.all.b1.innerHTML=d1;


document.all.b2.innerHTML=d2;


document.all.b3.innerHTML=sl2;


document.all.b4.innerHTML=d3;


document.all.b5.innerHTML=d4;


document.all.b6.innerHTML=sum2;




document.all.c1.innerHTML=q1;


document.all.c2.innerHTML=q2;


document.all.c3.innerHTML=sl3;


document.all.c4.innerHTML=q3;


document.all.c5.innerHTML=q4;


document.all.c6.innerHTML=sum3;




document.all.hj.innerHTML=sum4;


}


</script>
//计算输入结果到TD
function dosum()
{
var sum1,sum2,sum3,sum4;
var sl1,sl2,sl3;
sum1=0;sum2=0;sum3=0;sum4=0;
sl1=0;sl2=0;sl3=0;
var s1,s2,s3,s4,d1,d2,d3,d4,q1,q2,q3,q4;
s1=parseFloat(document.all.s1.value);//取值
s2=parseFloat(document.all.s2.value);
s3=parseFloat(document.all.s3.value);
s4=parseFloat(document.all.s4.value);
d1=parseFloat(document.all.d1.value);
d2=parseFloat(document.all.d2.value);
d3=parseFloat(document.all.d3.value);
d4=parseFloat(document.all.d4.value);
q1=parseFloat(document.all.q1.value);
q2=parseFloat(document.all.q2.value);
q3=parseFloat(document.all.q3.value);
q4=parseFloat(document.all.q4.value);
sl1=(s2-s1);//数量
sl2=(d2-d1);
sl3=(q2-q1);
sum1=sl1*s3+s4;//金额
sum2=sl2*d3+d4;
sum3=sl3*q3+q4;
sum4=sum1+sum2+sum3;
//输入出对应TD
document.all.a1.innerHTML=s1;
document.all.a2.innerHTML=s2;
document.all.a3.innerHTML=sl1;
document.all.a4.innerHTML=s3;
document.all.a5.innerHTML=s4;
document.all.a6.innerHTML=sum1;

document.all.b1.innerHTML=d1;
document.all.b2.innerHTML=d2;
document.all.b3.innerHTML=sl2;
document.all.b4.innerHTML=d3;
document.all.b5.innerHTML=d4;
document.all.b6.innerHTML=sum2;

document.all.c1.innerHTML=q1;
document.all.c2.innerHTML=q2;
document.all.c3.innerHTML=sl3;
document.all.c4.innerHTML=q3;
document.all.c5.innerHTML=q4;
document.all.c6.innerHTML=sum3;

document.all.hj.innerHTML=sum4;
}
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: