<style>
@media print {
.aa {display:none;}
}
</style>
<table id="datagrid1">
<tr><td>ok</td></tr></table>
<input type=button onclick="window.print()" value=print class="aa">
@media print {
.aa {display:none;}
}
</style>
<table id="datagrid1">
<tr><td>ok</td></tr></table>
<input type=button onclick="window.print()" value=print class="aa">
@media print{
INPUT {display:none}
}
</style>
<TABLE border="1" style="font-size:9pt;" width="300px">
<THEAD style="display:table-header-group;font-weight:bold">
<TR><TD colspan="2" align="center">每页都有的表头</TD></TR>
</THEAD>
<TBODY>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR style="page-break-after:always;"><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR style="page-break-after:always;"><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR><TD>表格内容</TD><TD>表格内容</TD></TR>
<TR style="page-break-after:always;"><TD>表格内容</TD><TD>表格内容</TD></TR>
</TBODY>
<TFOOT style="display:table-footer-group;font-weight:bold">
<TR>
<TD colspan="2" align="center">每页都有的表尾</TD>
</TR>
</TFOOT>
</TABLE>
<input type=button value=" 打 印 " onclick="window.print()">
@media print {
.aa {display:none;}
}
</style>
<table id="datagrid1">
<tr><td>ok</td></tr></table>
<input type=button onclick="window.print()" value=print class="aa">