Thread: cursor position
View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.misc
MarkT MarkT is offline
external usenet poster
 
Posts: 67
Default cursor position

Hi Gord,

Thanks for your post; it worked as you stated.

After working with Excel for ten years I can't believe just how much that I
don't know, and how much I have to learn yet.

Thanks for having the patience with me and others like me in this forum!

"Gord Dibben" wrote:

Mark

The code is to go into Thisworkbook module and is run automatically when the
workbook opens. Perhaps you didn't read that bit?

Copy the code as written then right-click on the Excel logo left of "File" on
the menu bar if window is maximized, on the Excel logo on window title bar if
not maximized.

Select "View Code". Paste the code into that module.

ALT + q to go back to Excel.

Choose another worksheet and cell.

Save/close and re-open to see Sheet1 and Z100 selected.

BTW......the reason it doesn't show in ToolsMacroMacros if you placed it in a
general module is the "Private" part.


Gord Dibben MS Excel MVP


On Tue, 6 Feb 2007 13:29:00 -0800, MarkT
wrote:

I entered in your macro as listed and ran it, and it indeed did work. I
saved the workbook and then opened it up again, however, the cursor was not
in the location that I specified in the macro.

Furthermore, when I went to edit the macro, it did not appear in the macro
window??? Not sure what's going on.

"Gary''s Student" wrote:

Yes:

The following macro will put the cursor in Z100 whenever the book is opened:

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


must be put in ThisWorkbook code.
--
Gary's Student
gsnu200704


"MarkT" wrote:

In Excel 2003, running XP Pro

Is there a way to have the cursor always be placed in a certain cell when a
workbook is opened up - regardless of where the user left it when they exited
out last?

Thanks for your help!

Mark