HTML, JavaScript And CSS Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
 
User Name:
Password:
Remember me
Go Back   ASP Free ForumsProgrammingHTML, JavaScript And CSS Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread ASP Free Forums Sponsor:
  #1  
Old April 12th, 2004, 04:56 AM
vbasp vbasp is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Aug 2003
Posts: 21 vbasp User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via ICQ to vbasp
Question Window.Print()

Hi there, I am using window.print method to print the current HTML page thru javascript which is working perfectly fine. But a small problem is that I am trying to print a tablular format data which spans across two pages. the headings of the table are displayed on the first page but not on the second page. What should I do to display the headings of the table on the second page also.

Reply With Quote
  #2  
Old April 12th, 2004, 12:09 PM
nschafer's Avatar
nschafer nschafer is offline
Contributing User
ASP Free Novice (500 - 999 posts)
 
Join Date: Mar 2004
Location: Florida
Posts: 584 nschafer User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 21 h 46 m 5 sec
Reputation Power: 5
I generally try to determine how many rows will fit on a page and loop the the data to close the table and start a new one for each page. You can force a page break after closing the table to ensure that the heading for the next page does indeed start on the next page.
__________________
Neal Schafer
The early worm gets eaten.

Reply With Quote
  #3  
Old June 15th, 2004, 01:47 PM
edp1959 edp1959 is offline
Contributing User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Posts: 36 edp1959 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 5
Do you have an example in more detail as to how you do this? Maybe some code?

Thanks

Reply With Quote
  #4  
Old July 6th, 2004, 07:16 AM
selwonk's Avatar
selwonk selwonk is offline
Contributing User
ASP Free Frequenter (2500 - 2999 posts)
 
Join Date: Jun 2004
Posts: 2,942 selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level) 
Time spent in forums: 6 Days 9 h 49 m 28 sec
Reputation Power: 62
You can also force the printed output to behave nicely for you. For example, you could start each page with <H2> and end it with <H3>. To make the page breaks work properly, you could add the following CSS:

Code:
<style>
h2 { page-break-before: auto; }
h3 {page-break-after: auto; }
</style>


MK

Reply With Quote
Reply

Viewing: ASP Free ForumsProgrammingHTML, JavaScript And CSS Help > Window.Print()


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway
Stay green...Green IT