473,563 Members | 2,856 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Print wide page

Hi,

I would like to ask for your help.

I am using IE5.5.

I have a wide page with horizontal scroll bar.
The problem is that I get only 1 page when printing it using
"file->print" or "window.pri nt".

The "print preview.. " displayed also 1 page only (page 1 of 1(

Is it IE problem or something with my printer?

Any JS tricks to bypass this problem?

Example:

try

<TABLE BORDER=1 CELLSPACING=1 CELLPADDING=0 >
<TR>
<TD><NOBR>Thi s is a long text, This is a long text, This is a long
text, This is a long text, This is a long text, This is a long text,
This is a long text, This is a long text, This is a long text, This is
a long text, This is a long text, This is a long text, This is a long
text, This is a long text, This is a long text, This is a long text,
This is a long text, This is a long text, This is a long text, This is
a long text, This is a long text, This is a long text, This is a long
text, This is a long text, This is a long text, This is a long text,
This is a long text, This is a long text, This is a long text, This is
a long text, This is a long text, This is a long text,
</td></tr>
</table>

Thanks,

Yaron
Jul 20 '05 #1
2 8352
VK
Actually what behavior do you want from your browser? You created a very
wide table and you told to browser (and printer) that it not allowed to
shrink the cells. There are not printers yet capable to stretch the
paper on runtime. So your printer prints each line until the right
margin limit, and the rest is being truncated. It's totally normal
behavior, not a bug.

Converting screen pixels to paper inches seems like converting gallons
to miles, but still there are some good approximations for it. At the
very first approximation, with a 1024x768 screen and portrait paper
orientation, your printable area is about 700 pixels (+- 50 pixels
depending on screen aperture and some printer settings). It means that
if you put the page content in a fixed width table, the first 700 pixels
from the left will be printed, and the rest will be truncated (I'm sure
you had a number of such printouts from different web-sites).

Solutions:
1) Re-think your data layout in the standard portrait orientation. I
know, now the landscape seems to you the only solution for your
particular case. Don't trust your feelings, it's an allusion :-)
Everything can be done in more than one way. And remember 700 pixels
limit.

2) Release printer: instead of table use <p> and <br> right on the page.
They will be properly wrapped on printing.

3) Windows provides an interface to change printer settings (switch from
portrait to landscape for example). Interface is on C++, so to access it
from the page you have to write an ActiveX and sign it properly. It
still doesn't solve the problem of really wide pages, where even
landscape will be not enough.

4) For each style sheet and for each particular style you can assign
MEDIA property. So you can have:
<link rel="stylesheet " href="..." media="page"> for displaying
<link rel="stylesheet " href="..." media="print"> for printer
Sounds like a real high-tech stuff, but it violates WYSIWYG principle.

I would still stay with the solution #1
Yaron Cohen <ya****@lyciumn etworks.com> wrote in message
news:1s******** *************** *********@4ax.c om...
Hi,

I would like to ask for your help.

I am using IE5.5.

I have a wide page with horizontal scroll bar.
The problem is that I get only 1 page when printing it using
"file->print" or "window.pri nt".

The "print preview.. " displayed also 1 page only (page 1 of 1(

Is it IE problem or something with my printer?

Any JS tricks to bypass this problem?

Example:

try

<TABLE BORDER=1 CELLSPACING=1 CELLPADDING=0 >
<TR>
<TD><NOBR>Thi s is a long text, This is a long text, This is a long
text, This is a long text, This is a long text, This is a long text,
This is a long text, This is a long text, This is a long text, This is
a long text, This is a long text, This is a long text, This is a long
text, This is a long text, This is a long text, This is a long text,
This is a long text, This is a long text, This is a long text, This is
a long text, This is a long text, This is a long text, This is a long
text, This is a long text, This is a long text, This is a long text,
This is a long text, This is a long text, This is a long text, This is
a long text, This is a long text, This is a long text,
</td></tr>
</table>

Thanks,

Yaron

Jul 20 '05 #2
Thanks VK,

Yaron
Jul 20 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

12
2459
by: Wes Groleau | last post by:
Is there a good how-to and/or example of a simple way to have a web page look decent on both screen (in most browsers) and in print? The example in the W3C CSS manual does NOT do it. -- Wes Groleau Even if you do learn to speak correct English,
2
2308
by: Luis Serrano | last post by:
Hi all, I'm trying to generate labels to print in several different formats, all of them with their own height,width and page margins. We've got this done in MS Access 2000, using a designed report that fits with each label type, and reads a table dinamically generated. But the problem is page margins. Does Access store page margins and...
4
3222
by: Fred | last post by:
I'm a newbie to JavaScript so be gentle. You know that funky IE margin issue that causes the right side of the page to get cut off when the user prints the html document? http://www.post-gazette.com/interact/20000120radin.asp Well… I'd like to warn/help the IE users of the issue before they print page. I want to combine a popup message...
1
3589
by: iwongu | last post by:
Hi, I have a question about std::wcout and its underlying C functions. According to C99, a stream have an orientation type that is one of byte-oriented or wide-one, and it is determined by the first using C function on that stream. And the specific orientation functions should not be applied to the stream that have other orientation.
31
4173
by: melinama | last post by:
Hello, I've looked through alt.html and this group for an answer to my question. However, I found only cranky arguments with, occasionally, bits of hard-to-understand code - out of context - each of which is slammed by the next people along in the thread. So I'm afraid to ask this but I need to know!...
6
5165
by: Greg Esres | last post by:
I have some text lines to print that are much longer than the width of the paper, maybe as much as 6 times. For a given page, I'd like everything that doesn't fit to print on a second page, and whatever doesn't fit there to go on a third page, etc, so that I can piece together the final output by laying the pages side by side. Things that...
9
2746
by: xprotocol | last post by:
Trying to print a web page that scrolls to right a bit. I would think IE would page break by default when it gets to the end of the sheet, but it doesn't, it just cuts off the print. This only needs to work in IE but FF does the same thing. I tried messing with some media="print" functionality on it but couldn't get any page breaks to...
6
9973
tdw
by: tdw | last post by:
the View Orders form in my Access database has a Print button on it. It has other buttons too, like Edit etc. These buttons used to be at the bottom of the form laid out horizontally, but this was causing the form to be just long enough vertically that some people when viewing it on their screen would have to scroll up or down to see the top or...
0
7583
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
8106
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7642
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7950
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
6255
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
1
5484
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
3626
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1200
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
924
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.