共用方式為


XML Editor

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

The XML Editor is based on the Windows Server 2008 Visual Studio Text Editor and includes additional support for the XML languages. The XML Editor includes the following features:

  • XML 1.0 syntax checking.

  • Schema validation while you type.

  • XML snippets support, including schema-generated snippets.

  • Support for Document Type Definition (DTD).

  • Support for XML Schema definition language (XSD) schema.

  • Creating an XML Schema from an XML instance document.

  • Converting a DTD or XML-Data Reduced (XDR) schema into an XML Schema.

  • XSLT 1.0 syntax checking.

  • Document outlining, so that elements can be expanded and collapsed.

  • Integration with the XML Schema Explorer. This provides a hierarchal view of XML Schemas.

    The XML Editor is invoked for well-known file extensions, such as .xml, .xsd, .xsl, and .config. It is also invoked on any unknown file extension if the file appears to contain XML. You can also open any file with the XML Editor by using the Open With option and selecting the XML Editor from the list.

Express Editions

The following XML Editor features are not available in the Visual Studio Express Editions:

  • Creating an XML schema from an XML instance document.

  • Viewing XSLT output from the XML Editor.

  • Smart validation while editing XSLT style sheets.

  • XML Schema Explorer.

In This Section

XML Document Validation Describes the syntax checking and validation features.

XML Editor IntelliSense Features Describes the editor IntelliSense functionality.

XML Snippets Describes how to use the XML snippets feature.

Editing XSLT Style Sheets Describes the XSLT editing experience.

Schema Cache Lists the schemas that are installed by the XML Editor.

XML Editor Components Describes the XML Editor user interface components.

Editing Text, Code, and Markup Provides information about the Text Editor.

XML Standards Reference Provides information about XML technologies, including XML, Document Type Definition (DTD), XML Schema definition language (XSD), and XSLT.

See Also

XML Tools in Visual Studio