+ Reply to Thread
Results 1 to 3 of 3

Is shared workbook open?

  1. #1
    Forum Contributor
    Join Date
    08-23-2011
    Location
    England
    MS-Off Ver
    Excel 2010
    Posts
    404

    Is shared workbook open?

    Hi all,

    I have researched this but can't seem to find anything that works for me. I have tinkered.

    I have an Excel file (xlsm) on a shared network. Quite simply (ahem!) I want to determine if the file is open (in any guise - read only, etc) from another workbook.

    Please Login or Register  to view this content.
    Something like that anyway.

  2. #2
    Forum Expert
    Join Date
    04-22-2013
    Location
    .
    MS-Off Ver
    .
    Posts
    4,418

    Re: Is shared workbook open?

    I'm not sure you would be able to check if a user has a file open in read-only mode. I would guess you can only check if it is locked or not.

    You might be able to create a workaround but I'm not sure if it would be worth it... You would have to add code to the workbook open and close events to update a textfile log which contains the state of the workbook but even then you would run into issues if excel crashes or if two users open it as read only (one would close it which would update the text file and the other would still have it open). Perhaps you could use the ontime method to regularly update the text file whilst the excel file is open and have a script change the status of it if it hasn't been accessed for a period of time.

    It's all a bit messy though and is unlikely to work well in practice. You can use the method here to check if it is open AND locked:
    http://www.mrexcel.com/forum/excel-q...ther-user.html

  3. #3
    Forum Contributor
    Join Date
    08-23-2011
    Location
    England
    MS-Off Ver
    Excel 2010
    Posts
    404

    Re: Is shared workbook open?

    Thanks Rag - i'll try that.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Macro to detect if a shared workbook is open
    By LAWDAWG in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 05-04-2016, 02:48 PM
  2. Auto open/close and update shared workbook
    By Nord in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-11-2009, 03:34 AM
  3. Shared workbook will only open as read-only
    By Christian411 in forum Excel General
    Replies: 1
    Last Post: 02-16-2009, 09:31 AM
  4. Shared Workbook (Workbook Open Code)
    By Chard in forum Excel General
    Replies: 5
    Last Post: 05-30-2007, 09:04 PM
  5. [SOLVED] Who has this (shared) workbook open
    By John Pierce in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-01-2005, 06:05 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1