Wrox Home  
Search P2P Archive for: Go

  Return to Index  

aspx_beginners thread: Margin with IE


Message #1 by "Mike Misconin" <michael.misconin@n...> on Fri, 21 Feb 2003 20:54:49
Can someone help with this?

Is there a way of setting the page setup (margin) in IE through ASP code?
Example:
right margin .25
left margin .25

I have a report in asp, which grabs database from SQL andI would like to 
be able to print it, but I had to manually change the margin settings 
with IE, I would like to have this done with the form page itself.  I am 
trying to account for anyone who would like to print this report not to 
have problems with formatting.

Thanks,
Mike
Message #2 by "Peter Lanoie" <planoie@n...> on Tue, 25 Feb 2003 14:30:29 -0500
Mike,

I have never heard of such a capability in HTML.  Keep in mind that the fact
you are writing something in ASP has nothing to do with what you can make
the client (browser) do.  They are seeing only HTML and whatever goes with
that (JavaScript, plugins, etc).

If you are worried about layout for printing, you should look into something
more robust than just printing a page in the browser.  You never know what
the client will have in their settings that could adversely affect the
printout.  Not only margins, but default OS font sizes, any number of things
like that.  PDFs are great for document formatting, especially for reports
and such.  Look into PDF generation or something equivalent.

Peter

-----Original Message-----
From: Mike Misconin [mailto:michael.misconin@n...]
Sent: Friday, February 21, 2003 20:55
To: aspx_beginners
Subject: [aspx_beginners] Margin with IE


Can someone help with this?

Is there a way of setting the page setup (margin) in IE through ASP code?
Example:
right margin .25
left margin .25

I have a report in asp, which grabs database from SQL andI would like to
be able to print it, but I had to manually change the margin settings
with IE, I would like to have this done with the form page itself.  I am
trying to account for anyone who would like to print this report not to
have problems with formatting.

Thanks,
Mike

Message #3 by "Mike Misconin" <michael.misconin@n...> on Thu, 27 Feb 2003 16:06:15
Thanks Peter, I will look into this.

Mike


> Mike,

I have never heard of such a capability in HTML.  Keep in mind that the 
fact
you are writing something in ASP has nothing to do with what you can make
the client (browser) do.  They are seeing only HTML and whatever goes with
that (JavaScript, plugins, etc).

If you are worried about layout for printing, you should look into 
something
more robust than just printing a page in the browser.  You never know what
the client will have in their settings that could adversely affect the
printout.  Not only margins, but default OS font sizes, any number of 
things
like that.  PDFs are great for document formatting, especially for reports
and such.  Look into PDF generation or something equivalent.

Peter

-----Original Message-----
From: Mike Misconin [mailto:michael.misconin@n...]
Sent: Friday, February 21, 2003 20:55
To: aspx_beginners
Subject: [aspx_beginners] Margin with IE


Can someone help with this?

Is there a way of setting the page setup (margin) in IE through ASP code?
Example:
right margin .25
left margin .25

I have a report in asp, which grabs database from SQL andI would like to
be able to print it, but I had to manually change the margin settings
with IE, I would like to have this done with the form page itself.  I am
trying to account for anyone who would like to print this report not to
have problems with formatting.

Thanks,
Mike


  Return to Index