Changing Printer Settings using ASP

Discussion in 'ASP General' started by Jeremy, Aug 8, 2003.

  1. Jeremy

    Jeremy Guest

    Hi, I have an asp page that is returning data from a database.
    Sometimes this data is quite a few rows long. Problem is the customer
    (blah) wants to be able to print this data and wants a header printed
    on every page. I figured this one out using style sheets and a little
    something like this (in case anyone wants to use this):

    br.page {
    page-break-before: always;
    }

    basically when I want a page break (when printing!) I put this in:

    <br class=""page"" />

    and everything turns out formatted all pretty. First problem is, this
    only works in IE5.5 or better (Make everyone upgrade!). And if they
    have netscape, opera, mozilla, etc. . they're screwed. This isn't a
    big deal for me because I am dealing with about 20-30 customers all
    with fairly new systems. ANYWAY, my main problem that I am having now
    is that when I print on my computer, the formatting is all nice and
    page breaks come at the right time and the margins on the left and
    right are about .75" each (note, my margins defined by my style sheet
    are, margin: 0% 1% 0% 1%;). But when I print on the other computers,
    some print like mine and some the margins are like .25" and it totally
    screws up my formatting! Is there any way to set a users margins,
    etc. using ASP/VBScript/Style Sheets??? Also, is there a way to force
    landscape rather than portrait when printing this page? THANK YOU
    VERY MUCH!!!

    -Jeremy
    Jeremy, Aug 8, 2003
    #1
    1. Advertising

  2. > with fairly new systems. ANYWAY, my main problem that I am having now
    > is that when I print on my computer, the formatting is all nice and
    > page breaks come at the right time and the margins on the left and
    > right are about .75" each (note, my margins defined by my style sheet
    > are, margin: 0% 1% 0% 1%;). But when I print on the other computers,
    > some print like mine and some the margins are like .25" and it totally
    > screws up my formatting! Is there any way to set a users margins,
    > etc. using ASP/VBScript/Style Sheets???


    Not using ASP. You might look at some client-side solutions, e.g. see
    http://www.aspfaq.com/2014
    Aaron Bertrand - MVP, Aug 8, 2003
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Samuel Lee
    Replies:
    0
    Views:
    503
    Samuel Lee
    Nov 11, 2003
  2. asjad
    Replies:
    2
    Views:
    5,139
    Ali Asjad
    Nov 1, 2005
  3. donet programmer
    Replies:
    3
    Views:
    1,520
    Gregory A. Beamer
    Nov 20, 2009
  4. gizzeta

    Printer settings

    gizzeta, Jun 24, 2004, in forum: Javascript
    Replies:
    1
    Views:
    81
    William Morris
    Jun 24, 2004
  5. Replies:
    5
    Views:
    134
Loading...

Share This Page