ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Specific cell selected when sheet opens...how??? (https://www.excelbanter.com/excel-discussion-misc-queries/72165-specific-cell-selected-when-sheet-opens-how.html)

Ron M.

Specific cell selected when sheet opens...how???
 
I want a specific cell to be selected when a worksheet is opened, so
the user can go right to work without having to find that cell, select
it, etc. I searched the newsgroup but can't find any articles on how
to do this. Can somebody help?

Thanks,
Ron M.


Chip Pearson

Specific cell selected when sheet opens...how???
 
You need a VBA procedure to do this. In the ThisWorkbook code
module, enter

Private Sub Workbook_Open()
' change the sheet and cell reference as desired
Application.Goto Worksheets("Sheet2").Range("B2"), True
End Sub


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com



"Ron M." wrote in message
oups.com...
I want a specific cell to be selected when a worksheet is
opened, so
the user can go right to work without having to find that cell,
select
it, etc. I searched the newsgroup but can't find any articles
on how
to do this. Can somebody help?

Thanks,
Ron M.




Roger Govier

Specific cell selected when sheet opens...how???
 
Hi Ron

Something like the following code copied into the This Workbook module,
would take the user to cell G10 of Sheet on opening the file

Private Sub Workbook_Open()
Sheets("Sheet1").Range("G10").Select
End Sub

Amend to suit the starting location you want.
To copy the code in, Right click on any tab in the Workbook and choose
View Code, to bring up the VB Editor.
If the Project Explore is not visible, press Ctrl+R to bring it up.
Locate your Workbook in the Explorer, and double click on the
ThisWorkbook module.
Copy the Code above and Paste into the Code pane (Press F7 to bring it
up, if not visible)
Press the Excel icon at top left to return to your sheet.
Save the file.

--
Regards

Roger Govier


"Ron M." wrote in message
oups.com...
I want a specific cell to be selected when a worksheet is opened, so
the user can go right to work without having to find that cell, select
it, etc. I searched the newsgroup but can't find any articles on how
to do this. Can somebody help?

Thanks,
Ron M.




Ron M.

Specific cell selected when sheet opens...how???
 
I know how to enter the code, I just didn't know what the code was.

You guys should get medals! Thanks!

Ron M.



All times are GMT +1. The time now is 08:57 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com