On more than one occasion I have had a reader write to me perplexed as to why every time they would open a workbook a dialog box would appear that said the file was locked and they would have to save changes under another name. Even after doing that, the dialog sill appears on the new workbook!
Well the simple truth of it is that sometimes good old Excel becomes confused just like we do at times and thinks your file is locked by another user when it isn’t.
The first thing I advised was to restart their computer or copy the workbook to another folder on their system. Restarting or copying the workbook to another folder can sometimes help clear up Excel’s confusion.
More than likely though, the cause of the problem is that there is some sort of macro running when the workbook is opened. Even if you save the offending workbook under a different name, it still has the macro saved with it and the process will just repeat itself all over again. You can test to see if this is the problem.
Follow the steps below to learn how:
- Open the workbook as you normally would, dismissing the dialog box.
- Select all the worksheets in your workbook by clicking the left-most worksheet and holding down your Shift key as you click on the right- most worksheet.
- Select Move or Copy Sheet from the Edit menu. (To display the proper dialog box in version 2007, display the Home tab of your Ribbon).
- Click the format tool in the Cells group and then select Move or Copy Sheet from the resulting submenu
- Using the To Book drop-down list, select new book.
- Be certain the Create a Copy check box is selected.
- Click OK.
Now you have two workbooks – the one you originally opened and the new, unnamed workbook.
Close the original workbook without saving and then save the new workbook under a new name. You should now be able to open the new workbook with no problems, as the macros are not copies when you follow the steps above.