View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Jeff Jeff is offline
external usenet poster
 
Posts: 921
Default Macro code to open a workbook only when closed

How can I check in a macro subroutine if the status of another file is open
or close. I would like to open another file only when it is not open.
Otherwise, Workbooks.Open Filename:="myfile.xls" simply returns an error
when the file is already open while the macro is running. Thanks a lot in
advance.