Hold Cells Q

  • Thread starter Thread starter John
  • Start date Start date
J

John

What piece of code would I use for the cursor to go to Cell K12 on Open? I
have it going to K12 at the moment but K12 is in top left hand corner of
screen, I wish A1 to be in that position


Thanks
 
Private Sub Workbook_Open()

With Worksheets(1)
.Range("A1").Select
.Range("K12").Activate
End With

End Sub
 
Thanks Mauro

Mauro Gamberini said:
Private Sub Workbook_Open()

With Worksheets(1)
.Range("A1").Select
.Range("K12").Activate
End With

End Sub
 
With the requirement that A1 be in the upper left corner of the screen,
perhaps consider using the Goto statement with the scroll option.
Here are two general ideas:

Private Sub Workbook_Open()
Application.Goto Range("A1"), True
Range("K12").Select

'or
Application.Goto Range("A1"), True

'Zoom in on Range
Range(Cells(1, 1), Range("K12").Offset(2, 2)).Select
ActiveWindow.Zoom = True
Range("K12").Select
End Sub

HTH
 

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