alternating between left and righ headers, odd and even pages or leafs using VBA

  • Thread starter Thread starter webbygeeza
  • Start date Start date
W

webbygeeza

I have reports that will printout to 1 or more pages.

I use the following code to determine how many pages there will be

ActiveSheet.VPageBreaks.Count

Is there a way of alternating the position of the header.

I.e.

If page 1 (odd) then

..LeftHeader = "My Header"

RightHeader = ""



Else if even (2,4,6 etc) page then

..LeftHeader = ""

..RightHeader = "My Header"



I am currently printing into one single .pdf with multi pages therein. It is
fine if the header is in the same position but I would like to do something
a little fancy.
 
Thank you Tom, short and precise.

My guess is then to set up page for printing individually by hide and unhide
columns per print setup.

Best wishes,
Ray

Can stop losing sleepo
 

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

Back
Top