41

A few of my users are in and out of various Excel 2007 spreadsheets all day. One of them reports that "50% of the time" she tries to open a spreadsheet from the file server, an information message comes up stating:

foo.xlsx is locked for editing

by 'another user'.

Open "Read-Only" or click "Notify" to open read-only and receive notification
when the document is no longer in use.

Nine times out of ten the document is not open by another user. My users immediately try to open the same document again, and it works.

I imagine this is caused by Excel leaving owner files on the server, but I do not know why.

An added clue: When one of my users selects "Notify," a dialog pops up in a moment informing them the file is available for them to edit.

Any guidance on how to solve this issue and make my users' days flow better?

2
  • You might get more/better answers on serverfault. Aug 27, 2009 at 21:50
  • 7
    I posted a similar basic-IT question on serverfault a few days ago and it got moved here. I'm stuck in the gray area between these two sites.
    – Chris
    Aug 27, 2009 at 21:52

11 Answers 11

32

Straight from Microsoft KB 313472:

This behaviour may occur if Word determines that the owner file for the document already exists. This may occur if one or more of the following conditions are true:

  • Word previously quit improperly and, therefore, did not delete the owner file. -or-
  • A second instance of Word is running in the background with the document already open. -or-
  • The document is shared over a network, and another user has it open.

From my personal experience, I've found a combination of the first and third point above can recreate this error quite constantly.

Temp files, left next to the original file on the network (especially if the file is large, she copy-pastes a LOT or it is open all day) are the cause.

To resolve this issue, first confirm that another user on the network does not have the document open. If the document is in use, open the document as read-only. If it is not in use, quit all instances of Word, and then remove the owner file. To do so, follow these steps.

NOTE: Because there are several versions of Microsoft Windows, the following steps may be different on your computer. If they are, see your product documentation to complete these steps.

  1. Quit all instances of Word. To do so, follow these steps: 1. Save all your work, and then quit all programs. 2. Press CTRL+ALT+DELETE to open the Windows Security dialog box. 3. Click Task Manager, and then click the Processes tab. 4. Click Winword.exe, and then click End Process. 5. In the Task Manager Warning dialog box, click Yes. If you receive a message that states that the program is not responding, click End Now. 6. Repeat steps d and e for each occurrence of Winword.exe. 7. On the File menu, click Exit Task Manager.
  2. Start Windows Explorer, and then browse to the folder that contains the document file that you tried to open when you received the error message.
  3. Delete the owner file.

    The owner file is located in the same folder as the document that you tried to open. The owner file name uses the following convention: It begins with a tilde (~), followed by a dollar sign ($), followed by the remainder of the document file name. The file name extension is .doc. For example, the owner file for Document.doc is named ~$cument.doc.

  4. Start Word. If Word asks you whether you want to load the changes that were made to the Global or Normal template, click No.
  5. Open your document.

Additional note for documents shared over a network:

If there are multiple people that could be editing the doc, it can sometimes be hard to figure out who might have the doc open. As shown on TechTalkMadness, the best way to find the answer is to use Computer Management on the system that hosts the shared file.

Go to Computer Management -> System Tools -> Shared Folders -> Open Files to find out who has a document locked. If the user can't be contacted to disconnect themselves, you can forcefully do so by right clicking the locked file and selecting Close Open File (warning: the user might lose their changes).

Use Computer Management -> System Tools -> Shared Folders -> Open Files to find out who has a document locked

5
  • 1
    I read that KB article. My users swear it isn't the case, but I'm going to watch them over the next few days and see if it might be.
    – Chris
    Aug 27, 2009 at 21:55
  • Bugger, this was a problem where I work for a particularly pedantic person who totally changed her tune (showering computer tech's with chocolates, etc) when this fixed her problem. I will ask around here for other solutions, too! Aug 27, 2009 at 23:13
  • 6
    Where's the part of this answer that makes the users' day flow better?
    – kmarsh
    Apr 26, 2010 at 16:46
  • 2
    Computer Management -> System Tools -> Shared Folders -> Open Files thank you @Matt'Trouble'Esse exactly what I need
    – ctwheels
    Jul 20, 2016 at 20:38
  • What if after deleting owner file, the problem still persist?
    – GeneCode
    Apr 19, 2019 at 7:18
10

Try turning off "Details" and "Preview" in explorer

I just had this problem and the MS knowledgebase article was no help (tell other users to close the document? This is a shared Excel workbook, they're supposed to be opened by multiple users!)

Anyway what solved our problem was by turning the details tab off in Explorer (this is under Windows 7 - click Organise where the menu bar is normally, then Layout, then make sure Details is unticked - and also Preview by the sounds of it.)

Doing this immediately fixed our problem. It seems that with the details tab visible it keeps the file open for too long and Office apps can't then access it. This also explains why people were having problems opening documents they had created themselves and nobody else was using.

1
  • Thank you!!!! This completely fixed the issue I've been having for ever with this! Excel says the file is locked by 'another user' when I'm the only one in it - navigate to a different directory and the problem goes away!
    – FreeMan
    Nov 9, 2015 at 21:31
8

Try turning off the Indexing service

I had this and resolved it by turning off Indexing Service in Windows. The effect was instant, so I suspect Indexing service had deadlocked on the file in question.

On XP, Turn off indexing service like this: click the Start button, then Search. From the window that opens, choose Change preferences (bottom left). Click "Without Indexing Service", the "No, do not enable Indexing service" radio button, and OK.

I found the problem by downloading handle.exe. handle.exe tells you which program has the file open, and in my case it turned out to be cidaemon.exe. A quick google confirmed that it is the actual indexer of Windows' indexing service.

Thanks Microsoft, another 2 hours of value added to my day.

2

The pop-up tip displayed by explorer also causes the problem (same effect as the details pane). Disable it in Folder options > View tab

2

Maybe incompatible office versions?

I've seen this error today, when another user genuinely did have the file open. The problem was that Excel tells the second user that it's 'another user' rather than reporting the first user's actual name, making it difficult to work out who has it open.

I assumed this should be the name in the Office/Excel options - this is set correctly for both users.

In our case the first user with the file open is on Excel 2007; the second user is on Excel 2010; perhaps there's some incompatibility which causes the second user's Excel to be unable to get the real name.

Update: install patch to fix name resolution

UPDATE 12 sept 2012: Load

  • KB2598133 for Office 2007 or
  • KB2598143 for Office 2010 (different packs for 32 and 64 bits!)

to fix the incorrect names in the message.

1

I had the exact same issue. Couldn't open file on a network share to edit. But none of suggestions helped.

Turned out that the issue was as follows: Previously computer was being used and logged in by a local account. After I joined AD, i copied Application Data and Local Settings folder (on Windows XP) to AD user profile. After the operation i later discovered that Local Settings\Application Data\Microsoft\Office didn't have permissions for newly created user and thus office was prompting me with this dialog for every file. I had previously tried disabling firewall/antivirus on host and client machines, disabling indexing service on host machine, but none helped.

So i set appropriate permissions for Office folder and everything now works.

1

If you have the preview pane turned on in Windows 7's Explorer, you will get this error. Turning off the preview pane worked for me.

1

Here is what I found in our environment. All users "My Documents" maps to a network share on our SAN. We run a terminal server with Office installed that utilizes the same network share on our SAN. If an end user is using an Office product, and then does not log off completely but rather X out, the the file is shown as locked by the person who installed Office on the terminal server (yours truly).

If the end user logs back in to the disconnected terminal server session and logs off properly, the Office application is then closed and the file is unlocked.

1

Use the Microsoft Flow Chart

There is an official Microsoft blogpost up. It even has a flow chart.

The main points are these:

  • Update Windows
  • Update Office
  • Disable Details Pane and Preview Pane
  • Configure OpLocks registry settings on client and reboot client.
  • Stop non-Microsoft services
1
  • This looks really handy! I hope it can help others in the future.
    – Chris
    Sep 14, 2017 at 14:07
0

Precisely, there's a program called Unlocker, which unlocks locked files or folders.

From wikipedia,

Unlocker is a tool that can trace and unlock the locking protection commonly used in files on Microsoft Windows. However, its main use is to terminate the processes that are using a certain file, or force the processes to stop using the file, so the user can safely delete, rename or move the file.

From official site,

Ever had such an annoying message given by Windows?

  • Cannot delete Folder: it is being used by another person or program.
  • Cannot delete file: Access is denied
  • There has been a sharing violation.
  • The source or destination file may be in use.
  • The file is in use by another program or user.
  • Make sure the disk is not full or write-protected and that the file is not currently in use.

Unlocker is the solution!

  1. Simply right click the folder or file and select Unlocker
  2. If the folder or file is locked, a window listing of lockers will appear
  3. Simply click Unlock All and you are done!

Be aware the installer comes with OpenCandy adware, just uncheck it while installing or use the portable version.

0

Another way, if you have access to the file server is to use the command openfiles.exe. In my case Word said I was locking the file, but openfiles.exe showed that it was a different user. Eg if part of the filename was "birthday", you'd use this command:

openfiles /query | findstr -i birthday

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .