Detecting if Excel Workbook is already open

  • Thread starter Thread starter RzB
  • Start date Start date
R

RzB

I have an Access db that opens an Excel .wks file
and dumps some data to it. I want to be able to
detect if the .wks file is already open. I have found
a number of older posts that have suggested ways
to do this but I don't seem to be able to get any of
them working. I'm using Access/Excel 2002.
Is there a simple way of doing this?
Many thanks,
Roy
 
First, find out whether Excel is open at all. If it is, loop through the
Workbooks collection of the Excel application, checking to see whether or
not your wks file is there.
 
He'll have troubles, though if he uses GetObject (which I assume is what you
have in mind), & there are several copies running.

TC
 
TC,Douglas,

I'll look at the sites you suggets. I was
hoping for a solution that did not drive
me down the API road.

Anyway - many thanks for your help.

Roy
 
Back
Top