SitePoint Sponsor

User Tag List

Results 1 to 7 of 7

Thread: printing in asp

  1. #1
    SitePoint Member
    Join Date
    Jun 2001
    Location
    kuala lumpur in malaysia
    Posts
    15
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    printing in asp

    hi,

    can i do some printing in asp? meaning that, i have a print button in the asp page that allow the user to print some records....

    hope u all can help me with this.... i'm new in asp....

    thanks.
    Helping you to get Certified!
    www.certifyexpress.com
    Ultimate Practice Exam!
    www.certifypro.com

  2. #2
    Serial Publisher silver trophy aspen's Avatar
    Join Date
    Aug 1999
    Location
    East Lansing, MI USA
    Posts
    12,939
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    ASP is a server side language, once the page gets sent to the browser ASP can do nothing with it.

    Most browsers have a print button however, so what is the problem you need to solve?
    Chris Beasley - I publish content and ecommerce sites.
    Featured Article: Free Comprehensive SEO Guide
    My Guide to Building a Successful Website
    My Blog|My Webmaster Forums

  3. #3
    Xbox why have you forsaken me? moospot's Avatar
    Join Date
    Feb 2001
    Location
    Clearwater, FL
    Posts
    3,615
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You can use client-side scripting (i.e. JavaScript) in an ASP page to print your pages as well.

  4. #4
    SitePoint Wizard big_al's Avatar
    Join Date
    May 2000
    Location
    Victoria, Australia
    Posts
    1,661
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I know theres a pretty detailed article on this on www.4guysfromrolla.com can't find the url at the moment, but if you do a search I'm sure You'll find what your looking for
    .NET Code Monkey

  5. #5
    SitePoint Member
    Join Date
    Jun 2001
    Location
    kuala lumpur in malaysia
    Posts
    15
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    thanks for replying back..... in javascript, there is the window.print(), but this will bring up the print dialog and can i just skip this dialog.....

    with the window.print(), the page will contain the records, the title of the asp page and the locatio of that asp page....

    all i want is to print the records.....

    hope u gus can help me with this problem, or i will have to stick with the window.print()....

    thanks....
    Helping you to get Certified!
    www.certifyexpress.com
    Ultimate Practice Exam!
    www.certifypro.com

  6. #6
    Serial Publisher silver trophy aspen's Avatar
    Join Date
    Aug 1999
    Location
    East Lansing, MI USA
    Posts
    12,939
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    That stuff on the top of the page is something the browser tags on, if you're printing from the browser there is no way around it from your perspective.

    I'm not sure from the user perspective it may be a setting somewhere that you can turn off, but you can't code around it.
    Chris Beasley - I publish content and ecommerce sites.
    Featured Article: Free Comprehensive SEO Guide
    My Guide to Building a Successful Website
    My Blog|My Webmaster Forums

  7. #7
    Xbox why have you forsaken me? moospot's Avatar
    Join Date
    Feb 2001
    Location
    Clearwater, FL
    Posts
    3,615
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You can possibly post the data you want in a popup window and have the user print from there with the window.print() function. At least you can eliminate unnecessary graphics and text.


Bookmarks

Posting Permissions

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