View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.programming
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default How to update all headers in Excel

Maybe someone will volunteer to help.

Or maybe you'll try it and see that it's not so difficult.

Brian wrote:

Is there any way to sent the Sheet to someone and let them do it. i am not
good at this.

"Dave Peterson" wrote:

Record a macro when you change the print setting for the master worksheet.

Delete the settings that you don't care about (it'll speed up the code).

Then you could use:

Option Explicit
Sub testme()

Dim MstrWks As Worksheet
Dim wks As Worksheet

Set MstrWks = Nothing
On Error Resume Next
Set MstrWks = ActiveWorkbook.Worksheets("MasterSheetNameHere")
On Error GoTo 0

If MstrWks Is Nothing Then
MsgBox "Design error!"
Exit Sub
End If

For Each wks In ActiveWorkbook.Worksheets
If wks.Name = MstrWks.Name Then
'skip it
Else
'do all the work you want.
With wks.PageSetup
.LeftHeader = MstrWks.PageSetup.LeftHeader
.CenterHeader = MstrWks.PageSetup.CenterHeader
'and on and on...
End With
End If
Next wks

End Sub

If you're new to macros:

Debra Dalgleish has some notes how to implement macros he
http://www.contextures.com/xlvba01.html

David McRitchie has an intro to macros:
http://www.mvps.org/dmcritchie/excel/getstarted.htm

Ron de Bruin's intro to macros:
http://www.rondebruin.nl/code.htm

(General, Regular and Standard modules all describe the same thing.)

Brian wrote:

We have an Excel Workbook with several different sheets (tabs). Some sheets
are Portrait and some are landscape. This workbook has a data input sheet for
alot of the data that is used on several of the sheets. We used the =('Input
Sheet'!D37)
to automate the data input, but we can't get the Header/Footnote to update.

Our problem is that the Header / Footnote Information is on the Data Input
Sheet already. How can we take the Data from Input Sheet and place it in the
Header / Footnote without changing all the page formatting?


--

Dave Peterson
.


--

Dave Peterson