Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.setup
Dan Dobill
 
Posts: n/a
Default How do I set a worksheet to be the default at startup?

I have a workbook that has more than 50 worksheets. I would like the default
to open to the first worksheet when the file is opened, not the last one
accessed when last saved. Is it possible to do easily?

thanks,
dan
  #2   Report Post  
Posted to microsoft.public.excel.setup
Dave Peterson
 
Posts: n/a
Default How do I set a worksheet to be the default at startup?

Put this in a general module:

Option Explict
sub auto_Open()
application.goto worksheets(1).range("a1"),scroll:=true
'or
application.goto worksheets("MyFavoriteSheet").range("a1"),scroll:= true
End sub

If you're new to macros, you may want to read David McRitchie's intro at:
http://www.mvps.org/dmcritchie/excel/getstarted.htm

Dan Dobill wrote:

I have a workbook that has more than 50 worksheets. I would like the default
to open to the first worksheet when the file is opened, not the last one
accessed when last saved. Is it possible to do easily?

thanks,
dan


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.setup
Dan Dobill
 
Posts: n/a
Default How do I set a worksheet to be the default at startup?

Thanks, Dave! works beautifully...after I changed the spelling of Explicit...

dan

"Dave Peterson" wrote:

Put this in a general module:

Option Explict
sub auto_Open()
application.goto worksheets(1).range("a1"),scroll:=true
'or
application.goto worksheets("MyFavoriteSheet").range("a1"),scroll:= true
End sub

If you're new to macros, you may want to read David McRitchie's intro at:
http://www.mvps.org/dmcritchie/excel/getstarted.htm

Dan Dobill wrote:

I have a workbook that has more than 50 worksheets. I would like the default
to open to the first worksheet when the file is opened, not the last one
accessed when last saved. Is it possible to do easily?

thanks,
dan


--

Dave Peterson

  #4   Report Post  
Posted to microsoft.public.excel.setup
Dave Peterson
 
Posts: n/a
Default How do I set a worksheet to be the default at startup?

Oopsie.

Glad it worked for you (after the fix!).

Dan Dobill wrote:

Thanks, Dave! works beautifully...after I changed the spelling of Explicit...

dan

"Dave Peterson" wrote:

Put this in a general module:

Option Explict
sub auto_Open()
application.goto worksheets(1).range("a1"),scroll:=true
'or
application.goto worksheets("MyFavoriteSheet").range("a1"),scroll:= true
End sub

If you're new to macros, you may want to read David McRitchie's intro at:
http://www.mvps.org/dmcritchie/excel/getstarted.htm

Dan Dobill wrote:

I have a workbook that has more than 50 worksheets. I would like the default
to open to the first worksheet when the file is opened, not the last one
accessed when last saved. Is it possible to do easily?

thanks,
dan


--

Dave Peterson


--

Dave Peterson
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Conversion of Cell Contents into a Functional Worksheet name ? GMJT Excel Worksheet Functions 1 August 21st 05 04:59 PM
Macro to search for and display data in another worksheet Mark H Excel Worksheet Functions 0 June 14th 05 12:40 PM
Increase default size of worksheet Westontony New Users to Excel 9 December 16th 04 11:03 PM
Executing macro for all worksheet from a different worksheet Biti New Users to Excel 3 December 8th 04 10:05 AM
Reference Data in Moved Worksheet tommcbrny Setting up and Configuration of Excel 1 December 1st 04 06:49 PM


All times are GMT +1. The time now is 06:52 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"