ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Problem formatting header font size (https://www.excelbanter.com/excel-programming/415726-problem-formatting-header-font-size.html)

WembleyBear

Problem formatting header font size
 
Hi

I have a worksheet that prints out on several pages and I have a problem
setting the font size in the header. Each of the pages has different amounts
of information so I've used FitToPages 1x1 to ensure that each page fills as
much of the page as possible and I suspect this is where the problem is. I
want the header to print in 10 point font size regardless of the text size on
the rest of the page, but this is not working - a portion of my code for this
page is below. How can I get the header font size to be the same on each page
regardless?


Sub Print_Summary()

ActiveSheet.PageSetup.PrintArea = "$A$1:$N$37"

With ActiveSheet.PageSetup
.CenterHeader = "&10STOWMARKET BUDGET " & Range("O1").Value
.FitToPagesWide = 1
.FitToPagesTall = 1

End With

ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
ActiveSheet.PageSetup.PrintArea = "$A$39:$N$95"

With ActiveSheet.PageSetup
.CenterHeader = "&10STOWMARKET BUDGET " & Range("O1").Value
.FitToPagesWide = 1
.FitToPagesTall = 1

End With
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True

End Sub


Thanks
Martyn

Excel 2000, Windows Server 2003 over Citrix PS4

Dave Peterson

Problem formatting header font size
 
I think that the only thing you can do is look at how much you adjusted the
scale by and use that to determine the size of your header.

So if you scaled to 50%, you'd use (or at least try) 20 point font.



WembleyBear wrote:

Hi

I have a worksheet that prints out on several pages and I have a problem
setting the font size in the header. Each of the pages has different amounts
of information so I've used FitToPages 1x1 to ensure that each page fills as
much of the page as possible and I suspect this is where the problem is. I
want the header to print in 10 point font size regardless of the text size on
the rest of the page, but this is not working - a portion of my code for this
page is below. How can I get the header font size to be the same on each page
regardless?

Sub Print_Summary()

ActiveSheet.PageSetup.PrintArea = "$A$1:$N$37"

With ActiveSheet.PageSetup
.CenterHeader = "&10STOWMARKET BUDGET " & Range("O1").Value
.FitToPagesWide = 1
.FitToPagesTall = 1

End With

ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
ActiveSheet.PageSetup.PrintArea = "$A$39:$N$95"

With ActiveSheet.PageSetup
.CenterHeader = "&10STOWMARKET BUDGET " & Range("O1").Value
.FitToPagesWide = 1
.FitToPagesTall = 1

End With
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True

End Sub

Thanks
Martyn

Excel 2000, Windows Server 2003 over Citrix PS4


--

Dave Peterson


All times are GMT +1. The time now is 05:17 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com