<%@ page language="C#" masterpagefile="~/templates/Documentation.master" inherits="Page" pagetitle="Defining Elements and Attributes in XML Schemas" keywords="Defining Elements and Attributes in XML Schemas"%>

Defining Elements and Attributes in XML Schemas

You can define an element or attribute as part of a complexType. You can also define an element or an attribute as a top-level item. In other words, in the XML document that defines the XML Schema, the element or attribute is a child of the xsd:schema element. An element or attribute that is an immediate child of the xsd:schema element is a global element or attribute.

A global element or attribute cannot

This section covers the following topics: