473,480 Members | 1,820 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

How to generate multipage Header and Footers using ASP.NET on web pages.

52 New Member
Hi,
I am developing an application in ASP .NET where I have to generate a Header and a Footer on my web pages. The issue is that, these headers and footers need to be dynamically placed on the page. For example, if the page length is 1 page, there will be only 1 header and 1 footer. But if the page length is larger, and when we do the print/print preview of the page and it goes to say more than 1 page, then I need the headers and footers on all the pages.

In abstract, I need the headers and footers on all the pages depending on the length of the page generated.

I am developing the application in ASP.NET 2.0.

Any help or suggestion will be appreciated.

Thanks
Pawan
Jul 24 '08 #1
4 2802
Frinavale
9,735 Recognized Expert Moderator Expert
I'm not sure if you're Printing the page and need these headers and footers to appear on each of the printed pages or if you just want a header and footer to appear on your page.


If you just want a header and a footer on the page, I would place the contents of the page in a panel that has the css "overflow:scroll". This will display the content inside the panel and allow the user to scroll through the content...keeping your header and footer in place.

Eg:
Expand|Select|Wrap|Line Numbers
  1. <asp:Panel ID="Header" runat="server"></asp:Panel>
  2.  
  3. <asp:Panel ID="Content" runat="server" style="overflow:scroll"></asp:Panel>
  4.  
  5. <asp:Panel ID="Footer" runat="server"></asp:Panel>
  6.  
-Frinny
Jul 24 '08 #2
nato24
1 New Member
You might want to look at doing a simple screen css using the page-break-after style. Only show header and footer on print.
Jul 25 '08 #3
ppuniversal
52 New Member
You might want to look at doing a simple screen css using the page-break-after style. Only show header and footer on print.
Thanks ....
How is this possible....
Can you provide me a more insight to this.
I need to print the header and footer on all pages I print.
Thanks Pawan
Jul 28 '08 #4
ppuniversal
52 New Member
I'm not sure if you're Printing the page and need these headers and footers to appear on each of the printed pages or if you just want a header and footer to appear on your page.


If you just want a header and a footer on the page, I would place the contents of the page in a panel that has the css "overflow:scroll". This will display the content inside the panel and allow the user to scroll through the content...keeping your header and footer in place.

Eg:
Expand|Select|Wrap|Line Numbers
  1. <asp:Panel ID="Header" runat="server"></asp:Panel>
  2.  
  3. <asp:Panel ID="Content" runat="server" style="overflow:scroll"></asp:Panel>
  4.  
  5. <asp:Panel ID="Footer" runat="server"></asp:Panel>
  6.  
-Frinny

Thanks ....
I need to print the header and footer on all pages I print.
The logic you are saying will have only 1 header and 1 footer, but I need according to the page. If the page will be printed on 1 page, then 1 set of header and footer. and it will depend on the number of pages...this is just like we have header and footers on word document !!
Thanks Pawan
Jul 28 '08 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

9
2295
by: Fred | last post by:
Hi, I'm sure there are a bunch of them, but googling just returned full-fledged CMS that require a DBMS and generate dynamic pages. I'd just like a script that would 1. look in a directory...
3
6857
by: will | last post by:
Dear All, can anyone help here? I need to use XML/XSLT to print out some documents which must all have the same letterhead and footer section on all pages. The section in between is dynamic XML,...
3
1912
by: John Crowley | last post by:
I keep running into this over and over again... I want a block server control that renders a header and footer, and child controls in between. But I don't want a templated control, for the...
9
8448
by: Phin | last post by:
Hi, I have spent some time trying to get the tabstrip and multipage to work (from the IE web controls). I read the article from:...
5
3560
by: Maileen | last post by:
Hi, I want to use the control MS Forms 2.0 Multipage because it allows to display several pages without displaying the Tab on the top (even if in design mode). However, when i place a simple...
1
4873
by: Ira | last post by:
I was successful in creating the multipage Tif files in VB.net using the following the following code: Public Sub SaveSeveralOnePageFilesInADir(ByVal DrNm As String, ByVal resultFl As String)...
4
2665
by: stevesj | last post by:
I have a web form that generates 4 or 5 printed pages of html and a few images. I know how to insert CSS page breaks. Is there a way to calculate on the server where the page will break - like...
3
4675
by: | last post by:
In my report I have a calculated field that counts the number of records of the underlying table, =Count(). This field is placed in the report's header. I'd like to repeat this value on every page...
4
2296
by: shaiful | last post by:
Hi. I have a simple problem with multipage. I placed Multipage control on my form, but there are only 2 pages in multipage control by default. I would like to increase more pages with multipage...
0
7033
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
6903
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...
0
7071
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...
0
6861
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...
1
4763
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...
0
4468
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
2987
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
2974
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
557
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.