How to make A1 the active cell in all visible worksheets ?

  • Thread starter Thread starter Luc
  • Start date Start date
L

Luc

......so that when i activate the sheet A1 is the cell in the upper left corner of my screen.

Thanx
 
in the dev environment (ALT+F11) open the project explorer (Ctrl+R), then right click the icon for ThisWorkbook and select View Code
add this code|:

Option Explicit
Private Sub Workbook_SheetActivate(ByVal Sh As Object)
Range("A1").Select
End Sub
.....so that when i activate the sheet A1 is the cell in the upper left corner of my screen.

Thanx
 
Hi,

ALT+F11 to open VB editor. Double click 'ThisWorkbook' and paste the code in
on the right

Private Sub Workbook_SheetActivate(ByVal Sh As Object)
Application.Goto ActiveSheet.Range("A1"), scroll:=True
End Sub

Mike
 
Patrick, Mike : Thanks for your help !!!!

Luc


Mike H said:
Hi,

ALT+F11 to open VB editor. Double click 'ThisWorkbook' and paste the code
in
on the right

Private Sub Workbook_SheetActivate(ByVal Sh As Object)
Application.Goto ActiveSheet.Range("A1"), scroll:=True
End Sub

Mike
 
Back
Top