Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Icetea
 
Posts: n/a
Default Automatically insert page break every 6 rows in excel doc

I have a very large excel document and I need to insert a page break, say
after a fixed number of rows eg 6 rows. To insert page break manually it will
take hours. Can anybody help ?
  #2   Report Post  
Ian
 
Posts: n/a
Default

Try this:

Sub insert_page_breaks()
For r = 7 To 100 Step 6
Worksheets("Sheet1").Rows(r).PageBreak = xlPageBreakManual
Next
End Sub

--
Ian
--
"Icetea" wrote in message
...
I have a very large excel document and I need to insert a page break, say
after a fixed number of rows eg 6 rows. To insert page break manually it
will
take hours. Can anybody help ?



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Insert rows based on specific value bob Excel Worksheet Functions 6 February 29th 08 08:11 PM
Insert a number of rows based on a value in a cell on active row iRocco Excel Discussion (Misc queries) 1 August 11th 05 06:18 AM
Page Break Sheri Excel Worksheet Functions 1 August 4th 05 05:59 PM
Repeating Rows and Columns on each page of print out BruceM Excel Discussion (Misc queries) 1 July 6th 05 12:28 PM
Protect Worksheet but allow to insert or delete rows Bob L Hilliard Excel Discussion (Misc queries) 2 June 9th 05 02:08 PM


All times are GMT +1. The time now is 11:13 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"