Inserting rows before page break
If you have 100 names and you set the print area to A1:J110, then applying
the filter and printing will include 10 rows at the bottom for each class
(barring going beyond the pagebreak).
the other way would be to have one fully formatted class sheet, then use the
autofilter on your data sheet, copy the rows over to the formatted sheet
(only visible rows are copied by default), print (clear that data), and
repeat for each class. (or use the advanced filter).
Working with pagebreaks is slow and unreliable. For instance, horizontal
pagebreaks which don't have data below them, don't even show up in the
pagebreaks collection - so you wouldn't be able to find them with code -
unless you counted down a fixed number of rows (assumes all row heights are
equal).
--
Regards,
Tom Ogilvy
Robert Christie wrote in message
...
Thank you for reply Tom.
I'm trying to fully automate the formating from a .CSV
file to a spreadsheet. A second sheet allows the user to
print all classroom sheets or specific classrooms. Using
autofilter will not give me the extra blank rows under
last name, hence the requirement to move rows down.
TIA
Bob C
-----Original Message-----
Seems it would be easer to just apply an autofilter
(Data=filter=Autofilter) filter on each room, print,
filter on the next
and so forth. (the dropdown arrows for the filter don't
print).
--
Regards,
Tom Ogilvy
Robert Christie
wrote in message
...
Hi everyone
I have a list of student names, M/F, D.O.B., Test
results
etc. sorted by their assigned classroom number. Rooms
numbers can vary in sequence and total off i.e.
4,5,6,9,12,16, etc.etc.
The number of students in each class can also vary but
a
classroom will always fit on the one page.
I can find the starting row of each room by using a
helper column and inserting a blank row and page
break.
What I would like to do is move the starting row of
room
5 down to row 38 (start of page 2 landscape format).
Then move room 6 down to row 74 (start of page 3
landscape format) and so on until and including the
last
room number, to end up with a classroom on each page
with
spare blank rows for teachers use.
The page size ,margins, headers and footers have been
set
previously.
Season Greetings to all.
Hope you can help.
TIA
Bob C
.
|