Excel Unique last page footer

ECS

Joined
Jan 17, 2018
Messages
1
Reaction score
0
How can I make the last footer on my sheet different to the rest. Excel 2013??

I know you can put a different first page or odd or even pages but how can i change the last page footer to be different from all other pages? one sheet that runs over 4 or 5 pages
 
Very nice question....ECS !
I take help from the following web page Ref: https://excelribbon.tips.net/T012548_Custom_Page_Numbers_on_Printouts.html


There are a few ways you can go about tackling this problem, all of them involving the little bit use of VBA. If you actually want to print all the pages reside on the current worksheet, then the following macro will set the center section of the Footer of the last page differently (as requested):

Sub Differet_Footer_for_the_Last_Page()
Dim J As Integer

For J = 1 To ActiveSheet.PageSetup.Pages.Count
If J = ActiveSheet.PageSetup.Pages.Count Then
ActiveSheet.PageSetup.CenterFooter = "Page " & J & "...THE END"

End If
ActiveSheet.PrintOut J, J
Next J
End Sub
 
Last edited:
Back
Top