S
swain.s
both work books are in C:\
the master workbook name is test
the slave workbook name is data
the master workbook name is test
the slave workbook name is data
Gary''s Student said:Include the following event macro in the workbook code area of the test
workbook:
Private Sub Workbook_Open()
Workbooks.Open ("C:\data.xls")
End Sub
Because it is workbook code, it is very easy to install and use:
1. right-click the tiny Excel icon just to the left of File on the Menu Bar
2. select View Code - this brings up a VBE window
3. paste the stuff in and close the VBE window
If you save the workbook, the macro will be saved with it.
To remove the macro:
1. bring up the VBE windows as above
2. clear the code out
3. close the VBE window
To learn more about macros in general, see:
http://www.mvps.org/dmcritchie/excel/getstarted.htm
To learn more about Event Macros (workbook code), see:
http://www.mvps.org/dmcritchie/excel/event.htm
Jacob Skaria said:--You can open multiple workbooks and save as workspace .xlw. Opening this
workspace would open all linked workbooks.
--VBA method...Set the security level to low/medium in
(Tools|Macro|Security). Open master workbook. Press Alt+F11 to launch VBE
(Visual Basic Editor). From the left treeview search for the workbook name
and click on + to expand it. Within that you should see the following
VBAProject(Your_Filename)
Microsoft Excel Objects
Sheet1(Sheet1)
Sheet2(Sheet2)
Sheet3(Sheet3)
This Workbook
Double click 'This WorkBook' and paste the below code to the right code pane.
Private Sub Workbook_Open()
Workbooks.Open Me.Path & "\data.xls"
End Sub
Save>Close and re-open master file..which should open the data.xls from the
same folder
If this post helps click Yes
Dave Peterson said:You didn't post a response to the last suggestion at your other post.
Dave Peterson said:Did you try recording a new macro when you do it manually?