Can VBA determine the first row number of each page of a long sheet?
Excel 2016
Can VBA determine the first row number of each page of a long sheet?
Excel 2016
By Dave Hawley (RIP)
Sub GetPageBreaksRows() Dim hPB As HPageBreak Dim lRow As Long If ActiveSheet.HPageBreaks.Count > 0 Then For Each hPB In ActiveSheet.HPageBreaks lRow = hPB.Location.Row MsgBox lRow Next hPB End If End Sub
Thanks
You're welcome