View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.misc
Gary''s Student Gary''s Student is offline
external usenet poster
 
Posts: 11,058
Default Can I link a cell's contents to the header or footer in Excel?

Try this tiny macro. It sets the center footer to the value in cell A1:

Private Sub Workbook_BeforePrint(Cancel As Boolean)
ActiveSheet.PageSetup.CenterFooter = Range("A1").Value
End Sub

This macro should be pasted in workbook code, not a standard module.
--
Gary's Student


"djoslyn" wrote:

I'm trying to set up spreadsheets where the footer changes depending on
certain cells contents. Has anyone been able to do that?

Thanks.