Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Check for open workbook
howdy all this should be relatively simple, i'm just not sure how to do it i have 2 workbooks A.xls and B.xls when i open A.xls, i want it to check and see if B.xls is open if B.xls is open, then do nothing if B.xls is not open, then open B.xls that's it i'm just not sure how to set the code to do it any help would be great :) thank -- georgi ----------------------------------------------------------------------- georgio's Profile: http://www.excelforum.com/member.php...fo&userid=1644 View this thread: http://www.excelforum.com/showthread.php?threadid=31907 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Check for open workbook
On Error Resume Next Set oWB2 = Workbooks("B.xls") On Error GoTo 0 If oWB2 Is Nothing Then MsgBox "Open workbook 2" End If -- HTH RP (remove nothere from the email address if mailing direct) "georgio" wrote in message ... howdy all this should be relatively simple, i'm just not sure how to do it i have 2 workbooks A.xls and B.xls when i open A.xls, i want it to check and see if B.xls is open if B.xls is open, then do nothing if B.xls is not open, then open B.xls that's it i'm just not sure how to set the code to do it any help would be great :) thanks -- georgio ------------------------------------------------------------------------ georgio's Profile: http://www.excelforum.com/member.php...o&userid=16440 View this thread: http://www.excelforum.com/showthread...hreadid=319072 |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Check for open workbook
I often open multiple workbooks by "referencing" them to the master workbook.
Open excel, go to macro and select VBA to open the VBA editor. Then go to tools and click references and browse to your files. "georgio" wrote: howdy all this should be relatively simple, i'm just not sure how to do it i have 2 workbooks A.xls and B.xls when i open A.xls, i want it to check and see if B.xls is open if B.xls is open, then do nothing if B.xls is not open, then open B.xls that's it i'm just not sure how to set the code to do it any help would be great :) thanks -- georgio ------------------------------------------------------------------------ georgio's Profile: http://www.excelforum.com/member.php...o&userid=16440 View this thread: http://www.excelforum.com/showthread...hreadid=319072 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
VBA to check is someone else has a workbook open | Excel Discussion (Misc queries) | |||
If Then to check if a workbook is open | Excel Discussion (Misc queries) | |||
Check if workbook open | Excel Discussion (Misc queries) |