Question: I would like to find out the first row number of the page1. 

Using the following code can find the last row number of page 1.

```
ThisWorkbook.Worksheets("Sheet1").HPageBreaks(1).Location.Row - 1

```

But I have to find the first row number of Page1.

Would anyone has idea on it?

Thanks a lot

Answer: 
You could try with `Sheets().PageSetup.PrintArea` property. This will return the address of range for all your pages. As a result you get something like this:

```
$G$12:$P$31   << for continuous range/pages >> see 1st screen shot below
$G$12:$P$31;$B$5:$E$20;$R$5:$U$20   << for non-continuous ranges/pages >> see 2nd screen shot below

```

**1st Picture:**
![enter image description here](https://i.stack.imgur.com/xFjCO.jpg)

**2nd Picture:**
![enter image description here](https://i.stack.imgur.com/uqVso.jpg)

Each time above the first row number is the first row number on first page. To get it you could try with one of the following solutions:

```
firstRow = Range(Replace(ThisWorkbook.Worksheets("Sheet1").PageSetup.PrintArea, ";", ",")).Row

```

or with the following solution:

```
firstRow = Split(Split(ThisWorkbook.Worksheets("Sheet1").PageSetup.PrintArea, ":")(0),"$")(2)

```

**Additional explanation**

Range address which you get from `.PrintArea property` uses semi-colon `(;)` to separate non-continuous ranges. We need to convert it to comma `(,)` if we want to use it in first solution above.
The following is not the nicest way of coding I have to admit. But I think, it is easy to read and it does the job (if I understood the problem correct).

```
Sub runningThroughSheets()

  Dim wsht As Worksheet
  Dim wholeRow As Range
  Dim counter As Integer
  Dim stopSearch As Boolean

  Set wsht = Application.ActiveWorkbook.Worksheets("Sheet1")

  counter = 0
  stopSearch = False
  Do While stopSearch = False
    If Range("A1").Offset(counter, 0).EntireRow.Hidden = False Then
        stopSearch = True
    End If
    counter = counter + 1
  Loop

  MsgBox counter

End Sub

```