PC Review


Reply
Thread Tools Rate Thread

can you specify a worksheet during file open in excel?

 
 
Tim_at_TDR
Guest
Posts: n/a
 
      19th Sep 2008
Looking for a way to output to multiple sheets when creating an excel file
from a program. Is there some command-line switch or other feature one can
use to specifiy which worksheet to open or write to when an excel file is
openned?
 
Reply With Quote
 
 
 
 
JLGWhiz
Guest
Posts: n/a
 
      20th Sep 2008
You can use the Workbook_Open event to specify which worksheet is active upon
opening.

Private Sub Workbook_Open()
Worksheets("Sheet3").Activate
End Sub

The above code snippet would go in the ThisWorkbook code module. To access
that code module, press Alt + F11. Either double click on ThisWorkbook in
the project window in the left panel of the screen, or right click on it and
then click on View Code from the drop down menu. If you put the above code
in that code module, it will bring up sheet 3 each time you open the workbook.

"Tim_at_TDR" wrote:

> Looking for a way to output to multiple sheets when creating an excel file
> from a program. Is there some command-line switch or other feature one can
> use to specifiy which worksheet to open or write to when an excel file is
> openned?

 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Open C:/examplefile.xls or file.txt from another excel worksheet =?Utf-8?B?Q2hheQ==?= Microsoft Excel Discussion 5 15th Feb 2007 04:30 PM
Re: Is there a way to open an excel file to a specific worksheet? Gord Dibben Microsoft Excel Misc 0 5th Dec 2006 10:29 PM
Any way to open an excel file directly to a worksheet? skiddyrow Microsoft Excel Misc 2 12th Jul 2005 01:39 PM
I need Code to open DBF file in an excel worksheet Jason Ward Microsoft Excel Programming 3 29th Apr 2005 07:09 PM
From HTML open a specific worksheet within a excel file =?Utf-8?B?ZXNvbGxlcg==?= Microsoft Excel Programming 3 18th May 2004 09:41 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 12:32 AM.