"cannot be accessed" error message when you try to save a workbook that was opened from a mapped drive location in Excel 2003 (835234)



The information in this article applies to:

  • Microsoft Office Excel 2003

Important This article contains information about modifying the registry. Before you modify the registry, make sure to back it up and make sure that you understand how to restore the registry if a problem occurs. For information about how to back up, restore, and edit the registry, click the following article number to view the article in the Microsoft Knowledge Base:

256986 Description of the Microsoft Windows Registry

SYMPTOMS

When you try to save a workbook that was opened from a mapped drive (such as Z:\folder) location in Microsoft Office Excel 2003, you may receive one of the following error messages:
'path\filename.xls' cannot be accessed. The file may be read-only, or you may be trying to access a read-only location. Or, the server the document is stored on may not be responding.
Runtime error 1004: Cannot access path\filename

CAUSE

This problem may occur if either of the following conditions is true:
  • On the File menu, you click Save As, and then type a UNC path (such as \\server\share) in the File name box to resave the file back to its original file name and location.
  • You programmatically save the file back to its original file name and location by using a UNC path (such as \\server\share).

WORKAROUND

To work around this problem, do one of the following:
  • On the File menu, click Save.

    Note Do not click Save As on the File menu to resave the file back to its original file name and location by using a UNC location.
  • Microsoft 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.

    Sub test()
    
       ActiveWorkbook.SaveAs ActiveWorkbook.Path & "\filename.xls"
    
    End Sub
    

RESOLUTION

This problem was first fixed in a hotfix that is now contained in a service pack. If you installed the latest Microsoft Office 2003 service pack, you do not have to install the hotfix.

Service pack information

This problem is corrected in Microsoft Office 2003 Service Pack 1.

To resolve this problem, obtain the latest service pack for Microsoft Office 2003. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:

870924 How to obtain the latest service pack for Office 2003

Hotfix information

How to obtain the hotfix

This issue is fixed in the Excel 2003 Hotfix Package February 29, 2004. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:

833855 Excel 2003 hotfix package: February 29, 2004


After you install this hotfix, follow the steps that are listed in the "More Information" section of this article to set the SupportUNCMappedDriveSaveAs registry key and to activate the hotfix.

STATUS

Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.
This problem was first corrected in Office 2003 Service Pack 1.

MORE INFORMATION

Warning If you use Registry Editor incorrectly, you may cause serious problems that may require you to reinstall your operating system. Microsoft cannot guarantee that you can solve problems that result from using Registry Editor incorrectly. Use Registry Editor at your own risk.
To activate this hotfix, follow these steps:
  1. Quit Excel 2003.
  2. Click Start, and then click Run.
  3. In the Open box, type regedit, and then click OK.
  4. Locate, and then click to select the following registry key:

    HKEY_CURRENT_USER\Software\Microsoft\Office\11.0\Excel\Options

  5. After you select the key that is specified in step 4, point to New on the Edit menu, and then click DWORD Value.
  6. Type SupportUNCMappedDriveSaveAs, and then press ENTER.
  7. Right-click SupportUNCMappedDriveSaveAs, and then click Modify.
  8. In the Value data box, type 1, and then click OK.
  9. On the File menu, click Exit to quit Registry Editor.

Modification Type:MajorLast Reviewed:4/7/2006
Keywords:kbQFE KBHotfixServer kbOffice2003sp1fix kbsavefile kberrmsg kbOffice2003preSP1fix kbfix kbbug KB835234 kbAudITPRO kbAudEndUser