View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
dclarkston dclarkston is offline
external usenet poster
 
Posts: 1
Default Determine last row before end of page on worksheet

I am trying to develop some reports in Excel from VB6.0. The reports
have multiple records that can span several rows. Each record has a
commments field in it, so the height of a cell can very greatly from
record to record. What I am trying to figure out is an easy way to
determine what was the last row on a page in excel, so that when it
goes to a new page, it will reprint the title and the column names.
Currently I am calculating the height of every row and then based on if
the pagesetup is landscape or portrait, comparing that number to the
total height of the page to determine when the page ends...Is there a
simpler way to achieve this?