Hi Rowan:
Thanks for everything. I will not touch the code any more as it is
creating my report. Thanks all your help and your patience.
Now I am trying to finalize it this way. I want to put only 2 reports
per page. Say after 2 reports, I will give a page break at line number
40. I know that 2 reports will take maximum 4o lines(including heading
etc). Each report has a word "J/J" in header line(That I can search).
So in each page I will have 2 headers with text "J/J". I was thinking
to code this way:
------------------------------------
dim i as Integer
dim fnd as Boolean
dim fndrng as Range
Set fndrng = activesheet.usedrange.find(what:="J/J")
do while(fnd=true)
i=i+1
if (i=2) then
activesheet.pagebreak.rows=40
i=0
end if
set activesheet.usedrange.findNext(what:="J/J")---I dont know exact
code.
end loop
--I know the above approach is not well enough. I would request you a
better idea.
Thanks again
--
jesmin
------------------------------------------------------------------------
jesmin's Profile:
http://www.excelforum.com/member.php...o&userid=29540
View this thread:
http://www.excelforum.com/showthread...hreadid=492932