View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Gord Dibben Gord Dibben is offline
external usenet poster
 
Posts: 22,906
Default Activate the top of sheet

Couple of methods.

Add this to your macro

Sub test()
Dim ws As Worksheet
For Each ws In ActiveWorkbook.Sheets
ActiveWindow.ScrollRow = 1
'Range("A1").Select 'If you wish
Next ws
End Sub

Or in Thisworkbook module

Private Sub Workbook_SheetActivate(ByVal Sh As Object)
ActiveWindow.ScrollRow = 1
End Sub


Gord Dibben MS Excel MVP

On Sat, 29 Jul 2006 21:09:13 -1000, "AD108" wrote:

I need to find a way to make the top of each sheet in a workbook visible
after my code runs. I tried "select" and "activate" but when you select
the sheet, the visible range is different.

Thanks in advance for help with this.