?
Solved

Problem with the "FileName is locked for editing by 'another user'" function

Posted on 2009-04-27
8
Medium Priority
?
667 Views
Last Modified: 2012-06-21
Hello,

We have a folder on the network share that has many word docs in it. We have users with read, write and modify rights and we have users with read only rights.

When a read, write and modify user opens a doc and another read, write and modify user tries to open the same doc they receive the message below:

FileName is locked for editing by 'another user'.
Do you want to:
Open a Read Only copy
Create a local copy and merge your changes later
Receive notification when the original copy is available

This is normal.

However, when a read only user opens the file, and then a read, write and modify user opens the same file, the read, write and modify user does not get the file locked for editing by.. message.
But they do get a (read only) tag at the top of the doc title bar.
The read, write and modify user cannot make changes even though they have the rights to do so. Is this normal?

Also is there a way to get notified when a read only user opens a file first and then the read, write and modify user opnes the same file second.

Thanks in advance.
I hope this was not too confusing.

Cepolly
0
Comment
Question by:cepolly
  • 4
  • 4
8 Comments
 
LVL 8

Expert Comment

by:Bradley Haynes
ID: 24243941
It is normal for a shared doc to be read only to others when it is already "checked out" by someone. What you have is a method to prevent corrupt data in a file due modifications by multiple users at the same time {BAD}.
 
This over ride utility may help with unlocking files if you must: Say someone forgot to close it etc.
http://download.cnet.com/Unlocker/3000-2248_4-10493998.html
 
0
 
LVL 1

Author Comment

by:cepolly
ID: 24246536
Sure I understand that.

My question is though:
Is it normal for a Full Control user to not be able to edit a doc that they opened 2nd, even though the person that opened it first, is in read only mode?

Also is there any mechanism or alert that can be setup to tell the full control user that the read only user has opened the doc 1st?
0
 
LVL 8

Expert Comment

by:Bradley Haynes
ID: 24246735
You can make a file management app to control document access and mods. using the command line with the commands and switches in the MSDN.
http://msdn.microsoft.com/en-us/library/bb540536(VS.85).aspx
This is geared toward Developers; which may or may not be information overload.
Do a Google search for File Management and/or Source Control application to learn more about application similar to "MS Source Safe" which may do what you want.
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 1

Author Comment

by:cepolly
ID: 24249268
Thanks for the link but yeah this is probably too much for these users.

I just need to know whether it's normal for a Full Control user to not be able to edit a doc that they opened 2nd, even though the person that opened it first, is in read only mode?
0
 
LVL 8

Expert Comment

by:Bradley Haynes
ID: 24252963
I would say it is normal. One file can be viewed by many which is why it is 'Read Only'. If one user has the file open and has 'Write' permissions than the file is locked for them if they open it first. Otherwise they get the messaged
 "FileName is locked for editing by 'another user'.
Do you want to:
Open a Read Only copy
Create a local copy and merge your changes later
Receive notification when the original copy is available"
For notification of a files' status. The message above is that notification.
0
 
LVL 1

Author Comment

by:cepolly
ID: 24253096
Let me ask you this way:

Is there a non-dev way for a user to know which read only user has the file opened so that they can ask them to close it?
0
 
LVL 8

Accepted Solution

by:
Bradley Haynes earned 2000 total points
ID: 24253534
Here is a script I found at: http://windowsitpro.com/article/articleid/24503/determine-who-has-a-file-open.html
 

Listing 1: Who Has File Open
On Error Resume Next
Dim fso
Dim FindPos, Input
Dim RowNumber, ColumnNumber, XL
ColumnNumber=1
RowNumber=1
Input = InputBox("Enter any part of Filename","Case Insensitive")
Set XL = CreateObject("Excel.Application")
XL.workbooks.add
XL.Visible = TRUE
XL.Cells(RowNumber, ColumnNumber).Value = "User"
XL.Cells(RowNumber, ColumnNumber+1).Value = "Path"
RowNumber=RowNumber+1
'  Bind to a file service operations object on servername" in the local domain.
Set fso = GetObject("WinNT://<servername>/LanmanServer")
' Enumerate resources
If (IsEmpty(fso) = False) Then
For Each resource In fso.resources
If (Not resource.User = "") And (Not Right(resource.User,1) = "$") Then
 
FindPos = Instr(1, resource.path, Input ,1)
If (FindPos <> 0) Then
XL.Cells(RowNumber, ColumnNumber).Value = resource.user
XL.Cells(RowNumber, ColumnNumber+1).Value = resource.Path
RowNumber=RowNumber+1
End if
End If
Next
End If
XL.Cells.EntireColumn.Autofit
Set XL=nothing
MsgBox "Done"
 
 

 
0
 
LVL 1

Author Comment

by:cepolly
ID: 24254645
Thanks for all your help.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

After seeing numerous questions for Dynamic Data Validation I notice that most have used Visual Basic to solve the problem. This suggestion is purely formula based and can be used in multiple rows.
We live in a world of interfaces like the one in the title picture. VBA also allows to use interfaces which offers a lot of possibilities. This article describes how to use interfaces in VBA and how to work around their bugs.
Office 365 is currently available in five editions. Three of them are for business use: Office 365 Business Essentials, Office 365 Business, and Office 365 Business Premium. Two of them are for home/personal use: Office 365 Home and Office 365 Perso…
In a previous video Micro Tutorial here at Experts Exchange (http://www.experts-exchange.com/videos/1358/How-to-get-a-free-trial-of-Office-365-with-the-Office-2016-desktop-applications.html), I explained how to get a free, one-month trial of Office …

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question