Results 1 to 3 of 3
  1. #1
    Join Date
    Dec 2003
    Posts
    454

    Unanswered: How to print the page on popup window

    On my ASP page on a popup window without tool bars, I would like to have a button to let the user print the page. How can I do it? Thanks in advance.

  2. #2
    Join Date
    Nov 2003
    Location
    Christchurch, New Zealand
    Posts
    1,618
    you should be able to put a button there that calls some javascript. I think the function is window.print(); but I can't be sure.

  3. #3
    Join Date
    Jul 2003
    Location
    SoCal
    Posts
    721
    To make the print dialog automatically pop, put an OnLoad function in your Body tag that calls a function. That function would look similar to:
    Code:
    function printWin(){
      window.print();
      window.focus();
      window.close();
    }
    There was some reason why the print function had to come first, but I can't for the life of me remember why.. *shrug*
    That which does not kill me postpones the inevitable.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •