Wrox Home  
Search P2P Archive for: Go

  Return to Index  

asp_web_howto thread: Printing from an HTML page


Message #1 by "Joe Ehrenfeld" <joee@v...> on Thu, 30 Aug 2001 22:50:32
I have an html document that needs to be printed. I need to do two things:



1) I need a button or link that lets the user print the document from the 

page. (Without the print button or link showing up on the printed document)

2) I need to remove the Internet Explorer headers and footers.



How can this be done using ASP and/or JavaScript



Thanks
Message #2 by "Drew, Ron" <RDrew@B...> on Fri, 31 Aug 2001 08:06:27 -0400
Put this in the body...I do it near the top somewhere...the button will show

however..............

<SCRIPT LANGUAGE="JavaScript">

<!-- Begin

if (window.print) {

document.write('<form>Press to '

+ '<input type=button name=print value="Print" '

+ 'onClick="javascript:window.print()"> this page!</form>');

}

// End -->

</script>







-----Original Message-----

From: Joe Ehrenfeld [mailto:joee@v...]

Sent: Thursday, August 30, 2001 6:51 PM

To: ASP Web HowTo

Subject: [asp_web_howto] Printing from an HTML page





I have an html document that needs to be printed. I need to do two things:



1) I need a button or link that lets the user print the document from the 

page. (Without the print button or link showing up on the printed document)

2) I need to remove the Internet Explorer headers and footers.



How can this be done using ASP and/or JavaScript



Thanks



Message #3 by "Coffey, Dana" <dcoffey@B...> on Fri, 31 Aug 2001 06:21:01 -0700
go to www.4guysfromrolla.com and do a search for "printer friendly" .

You'll then find that which you seek. :)



-----Original Message-----

From: Joe Ehrenfeld [mailto:joee@v...]

Sent: Thursday, August 30, 2001 5:51 PM

To: ASP Web HowTo

Subject: [asp_web_howto] Printing from an HTML page





I have an html document that needs to be printed. I need to do two things:



1) I need a button or link that lets the user print the document from the 

page. (Without the print button or link showing up on the printed document)

2) I need to remove the Internet Explorer headers and footers.



How can this be done using ASP and/or JavaScript



Thanks






  Return to Index