Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Charting / November 2003

Tip: Looking for answers? Try searching our database.

chart - Header/Footer

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
rekoop - 07 Nov 2003 18:41 GMT
Help...
Is is possible to insert a header and/or footer into
multiple charts(Excel 2000 or 2002)?   I was hoping I
could insert a common chart header/footer as is possible
with worksheets.  Any help appreciated.
Jon Peltier - 08 Nov 2003 04:56 GMT
You could set up the headers and footers on one chart (File menu > Page
Setup), then before doing anything else, select each subsequent chart in
turn and press the F4 key, which repeats this action.

You could also select a chart, then record a macro while setting up its
headers and footers.  Then edit the macro code to only do the headers
and footers, and leave out all that other page setup stuff.  The final
macro might look like this:

Sub ChartHeaderFooter()
    With ActiveChart.PageSetup
        .LeftHeader = "&BConfidential&B"
        .CenterHeader = "&D"
        .RightHeader = "Page &P"
    End With
End Sub

Then select each chart and run the macro.

To repeat this macro on all chart sheets and embedded charts in the
workbook, try this:

Sub AllChartsHeaderFooter()
  Dim oChart as Chart
  Dim oSheet as Object
  Dim oChtObj as ChartObject
  For Each oChart in ActiveWorkbook.Charts
    With oChart.PageSetup
      .LeftHeader = "&BConfidential&B"
      .CenterHeader = "&D"
      .RightHeader = "Page &P"
    End With
  Next
  For Each oSheet In ActiveWorkbook.Sheets
    For Each oChtObj in oSheet.ChartObjects
      With oChtObj.Chart.PageSetup
        .LeftHeader = "&BConfidential&B"
        .CenterHeader = "&D"
        .RightHeader = "Page &P"
      End With
    Next
  Next
End Sub

- Jon
-------
Jon Peltier, Microsoft Excel MVP
http://www.geocities.com/jonpeltier/Excel/index.html
_______

> Help...
> Is is possible to insert a header and/or footer into
> multiple charts(Excel 2000 or 2002)?   I was hoping I
> could insert a common chart header/footer as is possible
> with worksheets.  Any help appreciated.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.