How to print X rows per page in Excel?
If you have a range of data with multiple rows in Excel, and now you want to print this range by 3 rows per page, how should you do? This tutorial just talks about the manual method and quick tricks to print fixed rows per page in Excel.
Print X rows per page by insert page break manually
Print X rows per page by running VBA
Print X rows per page by Kutools for Excel
Print X rows per page by insert page break manually
To print fixed rows per page, what we need to do is to insert the page breaks every n rows.
For instance, here I want to print 3 rows per page, now I begin to insert page breaks by manual.
1. Select the 4th data, see screenshot:
2. Then click Page Layout > Breaks > Insert Page Break. See screenshot:
Now a page break is inserted under the 3rd row. See screenshot:
Now to repeat step 1 and step 2 to insert other page breaks.
Tip: If you want to insert page break every n row, select n+1 row, 2n+1 row, 3n+1 row…to insert page breaks.
3. Then you can go to File (Office button) > Print to print the data by 3 rows per page.
Print X rows per page by running VBA
If you have hundreds of rows needed to insert page breaks, the above manual method is not a good choice. If you are interested in VBA, this tutorial can introduce a VBA code to quickly insert page breaks in every nth rows.
1. Press Alt + F11 to enable Microsoft Visual Basic for Applications window.
2. Click Insert > Module, then paste below VBA code into the new Module window.
VBA: Insert page breaks every nth row.
Sub formatSheets()
For i = 3 To 11 Step 3
ActiveSheet.HPageBreaks.Add Before:=Cells(i + 1, 1)
Next
End Sub
3. Then press Run. And you can see page breaks are inserted in every 3rd row.
Tip: In the VBA code, 3 To 11 Step 3 means that to insert page breaks in every 3rd row from the 3rd row to 11th row, and you can change it based on your needs.
Print X rows per page by Kutools for Excel
However, for most of Excel green hands, VBA code is also not an easy way to solve the problem that print x rows per page. Here if you like to try a new thing, you can try to use Kutools for Excel, a handy Excel tool which can make Excel more interesting and easier, its Insert Page Break Every Row utility can quickly insert page breaks in every nth row as you need.
After free installing Kutools for Excel, please do as below:
1. Enable the worksheet you want to insert page breaks, and click Kutools Plus > Printing > Insert Page Break Every Row. See screenshot:
2. In the Insert Page Break Every Row dialog, type the interval number you want to insert page breaks, and click Ok. Then a dialog pops out to remind you how many breaks are inserted, just click OK to close it. See screenshot:
Insert Page Break In Every X Row
Best Office Productivity Tools
Supercharge Your Excel Skills with Kutools for Excel, and Experience Efficiency Like Never Before. Kutools for Excel Offers Over 300 Advanced Features to Boost Productivity and Save Time. Click Here to Get The Feature You Need The Most...
Office Tab Brings Tabbed interface to Office, and Make Your Work Much Easier
- Enable tabbed editing and reading in Word, Excel, PowerPoint, Publisher, Access, Visio and Project.
- Open and create multiple documents in new tabs of the same window, rather than in new windows.
- Increases your productivity by 50%, and reduces hundreds of mouse clicks for you every day!