Results 1 to 5 of 5

How To Create a macro for Cell References into Header for a workbook

Threaded View

  1. #1
    Registered User
    Join Date
    03-06-2012
    Location
    Mumbai
    MS-Off Ver
    Excel 2010
    Posts
    7

    Post How To Create a macro for Cell References into Header for a workbook

    Hi,

    I've the following macro:

    Sub HeaderData()
    With ActiveSheet.PageSetup
    .CenterHeader = Range("P1").Value & vbCr & Range("P2").Value & " " & Range("P3").Value
    End With
    End Sub
    Using this I can insert different cell references in header, but it needs to run everytime by opening every sheet, which is teadius.

    I'm looking for similar macro, which will run for a whole workbook while opening the file and should have a formatting option.

    Thanks,

    Vivek


    Moderator's Note: Welcome to the forum.Thank you for joining. Btw, when posting codes they should be enclosed with code tags. Select the code then hit the "#" sign. I'll do it for you now. Thanks.
    Last edited by vlady; 01-19-2013 at 01:01 AM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1