[Javascript] How to modify the browsers page setup parameters like orientation and margins?

William T. Simmons tsimmons at employmentlawadvisors.com
Thu Jan 16 14:58:33 CST 2003


Ed,
This is almost certainly one of those things that would have to be done via
IE-specific DHTML. The best place to start looking would be in the DHTML SDK
Reference section of the MSDN site:
http://msdn.microsoft.com/library/default.asp?url=/workshop/author/dhtml/ref
erence/dhtmlrefs.asp

I hope that URL doesn't come through munged. Anyway, although I haven't done
the exact thing you're talking about, I've got the hard copy equivalent to
the above resource and remember seeing it when researching something else. I
wish I could help in a more specific way. Good luck!

Tommy Simmons
Employment Law Advisory Network
www.employmentlawadvisors.com

----- Original Message -----
From: "Klinger, Edwin" <EKlinger at SUNTERRA.COM>
To: <javascript at LaTech.edu>
Sent: Thursday, January 16, 2003 1:18 PM
Subject: [Javascript] How to modify the browsers page setup parameters like
orientation and margins?

> Hello,
>
> I'm looking for a way in JavaScript to be able to set the
> browsers "Page Setup" properties. I'm specifically talking about IE
> 5+.
>
> I would like to be able to set the page orientation and margins. This
> is needed for printing purposes and not for displaying the page in
> the browser.
>
> I have a wide table that is about 900 in width that I need to print in
> landscape and adjust the browsers margins to fit this table on the
> paper. I will be opening a new window for printing this table using
> the window.open()method.
>
> I would like to set these properties myself and not have the user
> fiddle with them. Is this possible? Any other suggestions if not?
>
> Thanks for any help,
>
> Ed Klinger





More information about the Javascript mailing list