One Person per page

Occasional Visitor

Hello, I would like to edit an excel sheet in order to print 1 name per sheet.


For example:

On my sheet the Row A1 to A13 are requests done by Joe (In each row in the A column is written Joe W.)

From A14 to A27 are the requests done by Jane (In each row in the A column is written Jane C.)

and the list goes on....



I want to know if it's possible to print 1 Page per name. On the 1st Page you only see requests from Joe W. and on the 2nd Page the requests from Jane C.


Thank you.

1 Reply


Run this macro:

Sub SplitOnNames()
    Dim m As Long
    Dim r As Long
    m = Range("A" & Rows.Count).End(xlUp).Row
    Range("A" & m).Select
    For r = m To 2 Step -1
        If Range("A" & r).Value <> Range("A" & r - 1).Value Then
            ActiveSheet.HPageBreaks.Add Before:=Range("A" & r)
        End If
    Next r
End Sub