+ Reply to Thread
Results 1 to 3 of 3

Print multiple pages with different name.

  1. #1
    Annepaws
    Guest

    Print multiple pages with different name.

    I have set up a timesheet in excel that I would like to be able to print with
    each employees name on it. Is there a way of doing this without creating a
    sheet for each employee.

  2. #2
    Dave Peterson
    Guest

    Re: Print multiple pages with different name.

    Say you put the names of the employees on Sheet2 (a1:Axxx). And you want to
    print Sheet1 (and the names go into C1). Then you could run a little macro to
    print:

    Option Explicit
    Sub testme01()

    Dim myCell As Range
    Dim myNamesRng As Range
    Dim myHeaderCell As Range

    With Worksheets("sheet2")
    Set myNamesRng = .Range("a1", .Cells(.Rows.Count, "A").End(xlUp))
    End With

    With Worksheets("sheet1")
    Set myHeaderCell = .Range("C1")

    For Each myCell In myNamesRng.Cells
    myHeaderCell.Value = myCell.Value
    .PrintOut preview:=True
    Next myCell

    myHeaderCell.ClearContents

    End With

    End Sub

    (I used preview:=true to save paper while testing.)

    If you're new to macros, you may want to read David's intro at:
    http://www.mvps.org/dmcritchie/excel/getstarted.htm

    Annepaws wrote:
    >
    > I have set up a timesheet in excel that I would like to be able to print with
    > each employees name on it. Is there a way of doing this without creating a
    > sheet for each employee.


    --

    Dave Peterson

  3. #3
    Registered User
    Join Date
    01-05-2014
    Location
    Calgary, Alberta
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: Print multiple pages with different name.

    Hi Dave,

    What if you wanted to set a True/False condition for each employee? Therefore you could toggle what employee time sheet's are printed that day or week.

    i.e. Names in "A1" and the True/False Condition in "B1"

    Thanks!

+ Reply to Thread

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