How to prevent multi-access for XLAs?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

When Excel opens a workbook, it checks whether it is currently already open,
and in this case opens the workbook in read-only mode. This is good as it
prevents writing conflicts.

However I noticed that Excel won't check that lock, when the file is an
Addin. This is understandable since an Addin is supposed to Add functionality
to Excel, not store data, so that there is no need to handle concurrent
access.

However the Addin I made stores user data and I would like to have Excel to
warn the user that the Addin is in use, whenever someone else has opened it.

Is there a way to have that same warning Excel issues for workbooks, when an
addin is opened by a second user?
 
bReadOnly = Thisworkbook.ReadOnly

Note, if all previously opened instances containing the xla get closed, this
last one will remain .ReadOnly = true.

Regards,
Peter T
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top