Get Cell ID (eg. H40) at the top-left of the worksheet

  • Thread starter Thread starter LamNgo
  • Start date Start date
L

LamNgo

Hi group,

Is there any way to identify which cell is now at the top-left
position of the worksheet area. At the first time, it's always the A1
cell but atfer user scroll, how can we now what is the first visible
cell on the left-top corner?

Thanks,
LamNgo
 
Hi,

I don't think so. I tried to do this
and there are a few objects, like charts and shapes,
that have the visible property, but not individual
cells.

jeff
 
How about:

Option Explicit

Sub testme01()

With ActiveWindow
MsgBox .VisibleRange.Cells(1, 1).Address
MsgBox .ScrollColumn & vbLf & .ScrollRow
End With

End Sub

But watchout for windows|freeze panes applied.
 
'-------------------------------------------------------------------------
MsgBox (ActiveWindow.VisibleRange.Range("A1").Address)
'------------------------------------------------------------------------
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top