Notice: This website is an unofficial Microsoft Knowledge Base (hereinafter KB) archive and is intended to provide a reliable access to deleted content from Microsoft KB. All KB articles are owned by Microsoft Corporation. Read full disclaimer for more details.

Error message when you try to save a Word 2007 document: "You don't have permission to save in this location" or "Run-time error '5156'"


Symptoms

When you try to save a document in Microsoft Office Word 2007, you may experience one of the following symptoms:
  • When you click the Microsoft Office Button and then click Save or Save As to save the document in the root folder of the drive, the document is not saved. Additionally, you receive the following error message:
    C:\filename.doc
    You don't have permission to save in this location.
    Contact the administrator to obtain permission.

    Would you like to save in the username folder instead?
  • When you try to programmatically save the document in the root folder of the drive by using a Microsoft Visual Basic for Applications (VBA) macro, the document is not saved. Additionally, you receive the following error message:
    Run-time error '5156':

    Word cannot save or create this file. Make sure the disk you want to save the file on is not full, write-protected, or damaged.
    (C:\filename.doc)

↑ Back to the top


Cause

This behavior occurs if you try to save the Word 2007 document on a computer that is running Microsoft Windows Vista. By default, Windows Vista applies stronger security to the root folder of the drive.

↑ Back to the top


Workaround

To work around this behavior, do not try to save the Word 2007 document to the root folder of the drive. Instead, save the Word 2007 document to a different folder or subfolder. For example, save the Word 2007 document to the following folder:
C:\Users\username\Documents

↑ Back to the top


Keywords: kbtshoot, kbsavefile, kberrmsg, kbrtmpublic, kbexpertisebeginner, kbprb, kbentirenet, kb

↑ Back to the top

Article Info
Article ID : 923917
Revision : 3
Created on : 4/17/2018
Published on : 4/18/2018
Exists online : False
Views : 78