Select the product you need help with
Macro Code to Check Whether a File Is Already OpenArticle ID: 138621 - View products that this article applies to. This article was previously published under Q138621 For a Microsoft Excel 2002 version of this article, see 291295
(http://support.microsoft.com/kb/291295/EN-US/
)
.
For a Microsoft Excel 2000 version of this article, see 213383
(http://support.microsoft.com/kb/213383/EN-US/
)
.
On This PageSUMMARY
The following Microsoft Visual Basic for Applications procedure is an
example of how to determine if another user has a file open. This type of
macro is useful if you are using a file that is shared over a network
where only one user at a time should open the file.
MORE INFORMATIONMicrosoft provides programming examples for illustration only, without warranty either expressed or implied. This includes, but is not limited to, the implied warranties of merchantability or fitness for a particular purpose. This article assumes that you are familiar with the programming language that is being demonstrated and with the tools that are used to create and to debug procedures. Microsoft support engineers can help explain the functionality of a particular procedure, but they will not modify these examples to provide added functionality or construct procedures to meet your specific requirements. Sample Visual Basic ProceduresThis example checks to see if Book2.xls in the root directory of drive C is already open. If the file is not already open, the macro will open it.PropertiesArticle ID: 138621 - Last Review: August 17, 2005 - Revision: 2.1 APPLIES TO
|



Back to the top








