Changing all Dates on Headers
So run the macro on the 10th of each month and all will be well.
OR
Sub adjustit()
For Each sh In Worksheets
sh.Activate
v = ActiveSheet.PageSetup.CenterHeader
s = Format(Date, "mmmm 10, yyyy") & " - " & Split(v, "-")(1)
ActiveSheet.PageSetup.CenterHeader = s
Next
End Sub
run the above anytime and the Headers will go to the 10th of the current
month!!
--
Gary''s Student - gsnu200738
"Matt Dollar" wrote:
My bad.. forgot to mention I need to change the date monthly. Thus August
10, 2007 would need to change to September 10, 2007.
Thanks for your help though Gary"s Student
"Matt Dollar" wrote:
I have a workbook that I use monthly to Outline clients into different
regions. An example of one of the Headers is "August 10, 2007 - Ameritech
Business". My Problem is that the work book has 100+ tabs. Changing the
dates manually takes time that I now do not have. I searched and tried a few
trial and error codes but could not work it out. I would prefer to manually
run the code versus the dates being changed every print or every time the
workbook is opened.
I am also in need a diffrent code that would change the dates on Invidual
tabs. An example of one of the tabs is " Location Summary Dtl Aug 2007"
where the only change needed would be Aug to Sep.
I know I'm greedy!
Thanks for your help!
|