Header/Left margin

P

PO

Hi,

I run Excel 2k, SR1.

I'm formatting a report using PagesSetup.

I've reduced the reportsections left margin to 0.61... The problem is that
the header margin doesn't seem to use the body sections left margin, making
the text in the left header print a few points to the right of the rest of
the report.

Is there any way, using VBA, to also ajust the headers left margin?

TIA
Peter

[part of the code]

With ActiveSheet.PageSetup
.PrintTitleRows = "$1:$" & Range(strStartcell).Row
.LeftHeader = "&""Arial,Bold""&14Report Header"
.RightHeader = "&8&D"
.RightFooter = "&8&P(&N)"
.LeftMargin = Application.InchesToPoints(0.611811023622047)
.RightMargin = Application.InchesToPoints(0.611811023622047)
.TopMargin = Application.InchesToPoints(0.984251968503937)
.BottomMargin = Application.InchesToPoints(0.784251968503937)
.HeaderMargin = Application.InchesToPoints(0.511811023622047)
.FooterMargin = Application.InchesToPoints(0.411811023622047)
.Zoom = False
.FitToPagesWide = 1
.FitToPagesTall = False
End With
 
F

Frank Stone

you might try adding a few leading spaces to the text in
the left header to shift the text over to where you want
it. yes cheap i know but it works.
 
P

PO

Hi

I have the oposite problem - since my left margin is SMALLER then normal the
body text is to the LEFT of the report header.

Is there any solution to the problem?

Regards
Peter

Frank Stone said:
you might try adding a few leading spaces to the text in
the left header to shift the text over to where you want
it. yes cheap i know but it works.
-----Original Message-----
Hi,

I run Excel 2k, SR1.

I'm formatting a report using PagesSetup.

I've reduced the reportsections left margin to 0.61... The problem is that
the header margin doesn't seem to use the body sections left margin, making
the text in the left header print a few points to the right of the rest of
the report.

Is there any way, using VBA, to also ajust the headers left margin?

TIA
Peter

[part of the code]

With ActiveSheet.PageSetup
.PrintTitleRows = "$1:$" & Range(strStartcell).Row
.LeftHeader = "&""Arial,Bold""&14Report Header"
.RightHeader = "&8&D"
.RightFooter = "&8&P(&N)"
.LeftMargin = Application.InchesToPoints (0.611811023622047)
.RightMargin = Application.InchesToPoints (0.611811023622047)
.TopMargin = Application.InchesToPoints (0.984251968503937)
.BottomMargin = Application.InchesToPoints (0.784251968503937)
.HeaderMargin = Application.InchesToPoints (0.511811023622047)
.FooterMargin = Application.InchesToPoints (0.411811023622047)
.Zoom = False
.FitToPagesWide = 1
.FitToPagesTall = False
End With



.
 

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