Header & Footer text

  • Thread starter Thread starter SHETTY
  • Start date Start date
S

SHETTY

Dear Friends

I want to put value from a particular cell to header & footer text . Is this
is possible ?

I want to change the header footer text as and when text in the cell "A1"
cell changes

Please help

Ramesh Shetty
 
Hi

You can try that in Worksheet_Change event of that particular sheet

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Address = "$A$1" Then
ActiveSheet.PageSetup.CenterHeader = Range("C3")
ActiveSheet.PageSetup.CenterFooter = Range("D4")
End If
End Sub

Cheers
 
Thanks it works

ramesh

Shasur said:
Hi

You can try that in Worksheet_Change event of that particular sheet

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Address = "$A$1" Then
ActiveSheet.PageSetup.CenterHeader = Range("C3")
ActiveSheet.PageSetup.CenterFooter = Range("D4")
End If
End Sub

Cheers
 
Back
Top