Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
Ed Ed is offline
external usenet poster
 
Posts: 65
Default Prevent two network users from opening same workbook?

If a workbook is already open and a user tries to open it across a
network connection, they get the "Read Only / Notify" dialog. Is
there a convenient way to detect that one user already has the
workbook open, and prevent a second user from opening the file at all,
not even as Read Only?

Ed

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 175
Default Prevent two network users from opening same workbook?

There is no "convenient way" to do this. It can be done but is not
convenient as it requres using Windows API calls and a lot of faffing about.


--
http://www.alignment-systems.com


"Ed" wrote:

If a workbook is already open and a user tries to open it across a
network connection, they get the "Read Only / Notify" dialog. Is
there a convenient way to detect that one user already has the
workbook open, and prevent a second user from opening the file at all,
not even as Read Only?

Ed


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Prevent two network users from opening same workbook?

Ed,
You can add code to workbook's Open event and see if its .ReadOnly property
is true.
Then put up a msgbox and .Close.

However, if the user disables macros/events, then this will not function.
Or if the user actually wants it open as ReadOnly.

NickHK

"Ed" wrote in message
ups.com...
If a workbook is already open and a user tries to open it across a
network connection, they get the "Read Only / Notify" dialog. Is
there a convenient way to detect that one user already has the
workbook open, and prevent a second user from opening the file at all,
not even as Read Only?

Ed




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Prevent users to use a workbook/sheet after a specified day kelpie Excel Worksheet Functions 2 February 22nd 07 02:38 PM
Can I share a selfcert macro workbook with other network users KarenF Excel Discussion (Misc queries) 4 December 11th 06 11:22 PM
How to prevent any one from opening my workbook MMCM New Users to Excel 5 August 25th 06 07:54 PM
Prevent Users from unsharing a workbook Cillian Excel Worksheet Functions 0 June 21st 06 03:56 PM
How to allow multiple users to update workbook (on network)? quddusaliquddus Excel Discussion (Misc queries) 0 June 29th 05 07:33 PM


All times are GMT +1. The time now is 04:58 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"