Print a window
<html> <body> <script language="JavaScript"> function function1() { window.print(); } </script> <input type="button" value="Print this window" onclick="function1();"> </body> </html>