What does the Header Footer add to filesize?

P

Peter Noneley

Hello,

I have a workbook with 50 sheets.

On each sheet I put the same Custom Header and Custom Footer.

The Header/Footer is just plain text, (just 50 characters in total.)

After putting the Header/Footer on the 50 sheets the file size has
increased by approx 700k.

I also tried this on a new blank workbook and the same thing happens.

I don't think it is to do with the 'bloat' that sometimes occurs
infects a workbook.


My question is:

Does anyone know of a way to avoid the file size increase?

I use Win XP, Excel 2003.
The workbook has no VBA, and I need to keep it that way.

Thanks.

Peter.
 
D

Dave Peterson

I don't have a response for you, but I did do some experiments in xl2003 (winxp
home).

I added this to a new workbook with a single sheet (no data at all). I did use
my book.xlt as a template and that includes a footer (just the date).


Option Explicit
Sub testme()
Dim wks As Worksheet
Dim iCtr As Long

For iCtr = 1 To 50
Set wks = Worksheets.Add
'wks.PageSetup.CenterHeader = String(50, "x")
Next iCtr
End Sub

I ran it and saved the resulting workbook (51 sheets, all 51 with no headers).
The size was 111kb.

Then I closed that workbook and did the same thing, but uncommented the
centerheader line. The size was 218kb (for 51 sheets--51 with that header).

Then I started a new workbook and added a footer, too:

Option Explicit
Sub testme()
Dim wks As Worksheet
Dim iCtr As Long

For iCtr = 1 To 50
Set wks = Worksheets.Add
wks.PageSetup.CenterHeader = String(50, "x")
wks.PageSetup.CenterFooter = String(50, "z")
Next iCtr
End Sub

This resulted in a file of 221kb.

===========

I don't know what's going on with your installation, but something ain't right.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top