inserting page numbers into a column heading cell

C

compdinosaur

I have a worksheet with a column heading cell with the words "Page Number".
I would like to be able to insert the automatic page number here when the
page prints. I tried
"Page Number &[Page]" , but this just printed literally.
[I am a newbie]
 
A

AnimalMagic

I have a worksheet with a column heading cell with the words "Page Number".
I would like to be able to insert the automatic page number here when the
page prints. I tried
"Page Number &[Page]" , but this just printed literally.
[I am a newbie]


In the print setup, headers tab, choose custom header, and place the
&[Page] command in there. You can place spaces after it to space it in
from the right edge,and you adjust the header placement to change its
vertical placement.
 
J

Jacob Skaria

intTemp = 1
ActiveSheet.PageSetup.CenterHeader = "Page " & intTemp
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True


If this post helps click Yes
 
C

compdinosaur

I am really new at this and do not know how to use VBA or where to put the
code in Excel so I do not understand this answer. Basically I'd like to have
the code like what you can get in a custom header with a page number only
have it in a specific cell instead. Thank you for your response.

Jacob Skaria said:
intTemp = 1
ActiveSheet.PageSetup.CenterHeader = "Page " & intTemp
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True


If this post helps click Yes
---------------
Jacob Skaria


compdinosaur said:
I have a worksheet with a column heading cell with the words "Page Number".
I would like to be able to insert the automatic page number here when the
page prints. I tried
"Page Number &[Page]" , but this just printed literally.
[I am a newbie]
 
C

compdinosaur

I know how to get the page numbering in a custom header like you said, but
I'd like to get the same result in a cell that is in a Print Title column
that prints on the top of each page rather than the standard header. [I do
not know how to use VBA]
Thank you for your response.

AnimalMagic said:
I have a worksheet with a column heading cell with the words "Page Number".
I would like to be able to insert the automatic page number here when the
page prints. I tried
"Page Number &[Page]" , but this just printed literally.
[I am a newbie]


In the print setup, headers tab, choose custom header, and place the
&[Page] command in there. You can place spaces after it to space it in
from the right edge,and you adjust the header placement to change its
vertical placement.
 

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