- 爱易网页
-
ASP教程
- 急 在打印时,怎么隐藏这三个按钮?
日期:2014-05-17 浏览次数:21056 次
急!!! 在打印时,如何隐藏这三个按钮??
<HTML> <HEAD>
<META http-equiv=Content-Type content= "text/html; charset=gb2312 ">
<META content= "MSHTML 5.50.4522.1800 " name=GENERATOR> </HEAD>
<BODY>
<OBJECT id=WB classid=CLSID:8856F961-340A-11D0-A96B-00C04FD705A2 width=0 height=0> </OBJECT>
<TABLE width=800 border=1>
<TBODY>
<TR>
<TD align=middle colSpan=2> <STRONG> 案件报警登记 </STRONG> </TD> </TR>
<TR>
<TD> <P align=left> 打因设置打印预览 </P> </TD>
<TD> <P align=right> 打因设置打印预览 </P> </TD> </TR>
<TR height=300> </TR>
</TBODY>
</TABLE>
<TABLE width= "800 ">
<TBODY>
<TR align=right>
<TD>
<INPUT id=button1 onclick=doPrintSetup() type=button value=打印设置 name=button1>
<INPUT id=button2 onclick=doPrintPreview() type=button value=打印预览 name=button2>
<INPUT id=button3 onclick=Print() type=button value=打印 name=button3>
</TD>
</TR>
</TBODY>
</TABLE>
<SCRIPT language=JavaScript>
function doPrintSetup(){
//打印设置
WB.ExecWB(8,1)
}
function doPrintPreview(){
//打印预览
//window.id1.style.display= " "
window.button1.style.display= 'none '//..........
window.button2.style.display= 'none '//..........
window.button3.style.display= 'none '//隐藏打印按钮
WB.ExecWB(7,1)
}
function Print(){
//WB.ExecWB(6,1)// 和这个效果一样window.print()
WB.ExecWB (6,1)
}
</SCRIPT>
</BODY> </HTML>
------解决方案--------------------
http://hi.baidu.com/see7di/blog/item/7dca1a238bd3594f93580742.html
------解决方案--------------------
当表的border=1时,打印就能带着表格的线,
但border=0时,打印就不带表格的线,为什么?