Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default open workbooks when opening an excel file


I have 2 workbooks- workbook A contains a master job list and workbook
contains employees time allocated on a job. The master job lis
(workbook A) changes often so I have created a link between the
workbooks. I would like to create a macro that will open workbook
when I open workbook B. I assume I would put this in the open workboo
event

--
jprogramme
-----------------------------------------------------------------------
jprogrammer's Profile: http://www.excelforum.com/member.php...fo&userid=2978
View this thread: http://www.excelforum.com/showthread.php?threadid=54686

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default open workbooks when opening an excel file

Private Sub Workbook_Open()
workbooks.Open "C:\MyFolder\Workbook B.xls"
End Sub

go into the VBE (alt + F11), then in the project explorer on the left,
select your workbook and double click on the ThisWorkbook entry under your
project. this should open the thisworkbook module. At the top of the
module, in the left dropdown select Workbook and in the right down select
Open.

Modify at the second line above (adjusted for your specifics).

--
Regards,
Tom Ogilvy


"jprogrammer" wrote:


I have 2 workbooks- workbook A contains a master job list and workbook b
contains employees time allocated on a job. The master job list
(workbook A) changes often so I have created a link between the 2
workbooks. I would like to create a macro that will open workbook A
when I open workbook B. I assume I would put this in the open workbook
event?


--
jprogrammer
------------------------------------------------------------------------
jprogrammer's Profile: http://www.excelforum.com/member.php...o&userid=29781
View this thread: http://www.excelforum.com/showthread...hreadid=546863


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
opening a file in Excel starts application but dose not open file Bob Shelton Excel Discussion (Misc queries) 1 July 2nd 08 07:51 PM
how do i stop 16 workbooks from opening when I open excel 2007? GaryDolman Excel Discussion (Misc queries) 1 January 4th 08 08:07 PM
workbooks.open function fails to open an existing excel file when used in ASP, but works in VB. san Excel Programming 1 January 3rd 06 03:22 AM
when opening an excel file, two files open Brian Excel Discussion (Misc queries) 1 December 13th 05 07:24 PM
Excel 2003 Workbooks.Open with CorruptLoad=xlRepairFile fails on Excel 5.0/95 file due to Chart, with Error 1004 Method 'Open' of object 'Workbooks' failed Frank Jones Excel Programming 2 June 15th 04 03:21 AM


All times are GMT +1. The time now is 07:45 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"