Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default To determine that cell is on top of page

Hi,

Is there a way to determine that the cell is on the top of the page, e.g. in
Page Break Preview?
Thank you.

--
Andrei.


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,934
Default To determine that cell is on top of page

I think this function will do what you want...

Function IsTopOfPage(SheetName As String, RowNumber As Long) As Boolean
With Worksheets(SheetName)
IsTopOfPage = .Rows(RowNumber).PageBreak < xlPageBreakNone
End With
End Function

Just pass it the name of worksheet (as a String value) and the row number of
the cell you want to check and it will return True if that cell is located
on the top row of a page.

--
Rick (MVP - Excel)


"Andrei Zakharov" wrote in message
...
Hi,

Is there a way to determine that the cell is on the top of the page, e.g.
in
Page Break Preview?
Thank you.

--
Andrei.



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
A way to Determine visible cells on the page Mark Stephens Excel Programming 1 June 2nd 08 05:51 PM
Determine last row before end of page on worksheet dclarkston Excel Programming 1 September 16th 05 07:25 AM
Determine page which row will print on Fred Smith Excel Programming 0 July 22nd 04 05:49 AM
determine page number in Word document Cath Victor Excel Programming 0 July 13th 03 08:39 AM
Determine maximum length of a page Vasant Nanavati[_2_] Excel Programming 0 July 12th 03 03:20 AM


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

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

About Us

"It's about Microsoft Excel"