Opening other spreadsheets when one is opened

  • Thread starter Thread starter Todd
  • Start date Start date
T

Todd

I was curious if it is possbible that when a networked
spreadsheet is open and is linked to other spreadsheets,
if it is possible to automatically open the other
spreadsheets it is linked too? Thanks for the help.

Todd
 
You could probably use some code to cycle through the links, but maybe easier
would be to set a reference to every workbook you want open when open that
workbook.

First, you'll have to do a little housekeeping.

Open each workbook and go to the VBE (alt-F11 is a quick way).
Hit ctrl-R to see the project explorer
hit F4 to see the properties window
click on the line that looks like: VBAProject (book1.xls)
in the properties window, change VBAProject to a nice unique name.
(Each project has to have a unique name to use references.)
Save that workbook (but keep it open).

(do all of those linked workbooks)

Now in the "master" workbook's project (inside the VBE):
tools|references
and check each of the projects you want (that's where the unique name is
required)

Save your workbook with the references.

Close excel (for a test).

Open your master workbook.

Did all of the others open, too?

====
And you won't be able to close a workbook if another open workbook has a
reference to it.
 
Back
Top