Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Automatically display specific Excel sheet & range

Status
Not open for further replies.

wiginprov

Technical User
May 5, 2001
35
US
I have placed the following syntax in the general declarations section (VBA Project, Microsoft Excel Objects, ThisWorkbook) of a workbook, in an attempt to coax the file to always open with the cursor in a specific location, but it is not working. Does anyone have any suggestions?

Worksheets("Sheet1").Activate
Range("A6:a6").Select


 
Try this,

Worksheets("Sheet1").Activate
Range("A6").Select

And the right cell will be activated when the macro runs. It may be off the visible screen, and you may have to open the file and save it looking at the correct general area.
 
If that works for ya, great, but I think you'll need something more like:

Sub Workbook_Open()
Worksheets("Sheet1").Activate
Range("A6").Select
End Sub
 
Thank you segmentationfault and Goska. That makes sense and IT WORKS! THANK YOU!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top