Partilhar via


Documents, Environment, Options Dialog Box

Note

This article applies to Visual Studio 2015. If you're looking for the latest Visual Studio documentation, see Visual Studio documentation. We recommend upgrading to the latest version of Visual Studio. Download it here

Use this page of the Options dialog box to control the display of documents in the integrated development environment (IDE) and manage external changes to documents and files. You can access this dialog box by clicking Options on the Tools menu and then selecting Documents in the Environment node. If Documents does not appear in the list, select Show all settings in the Options dialog box.

Note

The options available in dialog boxes, and the names and locations of menu commands you see, might differ from what is described in Help depending on your active settings or edition. To change your settings, choose Import and Export Settings on the Tools menu. For more information, see Customizing Development Settings in Visual Studio.

Reuse current document window, if saved When selected, closes your current document if it has been saved, and opens a new document in the same window. If your current document has not been saved, it remains open and the new document is opened in a separate window. When this option is cleared, new documents always open in separate windows.

If you perform multi-document cut and paste operations infrequently and want to minimize the number of open documents and windows in your working space, try this option.

Detect when file is changed outside the environment When this option is selected, a message immediately notifies you of changes to an open file that have been made by an editor outside the IDE. The message lets you reload the file from storage.

Auto-load changes, if saved When you have Detect when file is changed outside the environment selected and an open file in the IDE changes outside the IDE, a warning message is generated by default. If this option is enabled, no warning appears and the document is reloaded in the IDE to pick up the external changes.

Allow editing of read-only files; warn when attempt to save When this option is enabled you can open and edit a read-only file. When you are finished, you must use the Save Ascommand to save the file by a new name if you want to save a record of your changes.

Open file using directory of currently active document When selected, this option specifies that the Open File dialog box displays the directory of the active document. When this option is cleared, the Open File dialog box displays the directory last used to open a file.

Check for consistent line endings on load Select this option to have the editor scan the line endings in a file and display a message box if inconsistencies are detected in how line endings are formatted.

Display warning when global undo will modify edited files Select this option to display a message box when the Global Undo command will roll back refactoring changes made in files that also were changed after the refactoring operation. Returning a file to its pre-refactoring state might discard subsequent changes made in the file.

Show Miscellaneous files in Solution Explorer Select this option to display the Miscellaneous Files node in Solution Explorer. Miscellaneous files are files that are not associated with a project or solution but can appear in Solution Explorer for your convenience.

Note

Select this option to enable the View in Browser command on the File menu for Web documents not included in the active Web application.

< n > items saved in the Miscellaneous files project Specifies the number of files to persist in the MiscellaneousFiles folder of Solution Explorer. These files are listed even if they are no longer open in an editor. You can specify any whole number from 0 to 256. The default number is 0.

For example, if you set this option to 5 and have 10 miscellaneous files open, when you close all 10 files, the first 5 will still be shown in the Miscellaneous Files folder.

Save documents as Unicode when data cannot be saved in codepage Select this option to cause files containing information incompatible with the selected codepage to be saved as Unicode by default.

See Also

Environment Options Dialog Box Miscellaneous Files Finding and Replacing Text