set custom header
Sub CustomHeader()
Dim myText As String
myText = InputBox("Enter your text here",
"Enter Text")
With ActiveSheet.PageSetup
.LeftHeader = ""
.CenterHeader = myText
.RightHeader = ""
.LeftFooter = ""
.CenterFooter = ""
.RightFooter = ""
End With
End Sub
No comments:
Post a Comment
THANKS FOR YOUR SUPPORT