Form Property
Collapse the table of content
Expand the table of content

XmlArrayItemAttribute.Form Property

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

Gets or sets a value that indicates whether the name of the generated XML element is qualified.

Namespace:  System.Xml.Serialization
Assembly:  System.Xml (in System.Xml.dll)

public XmlSchemaForm Form { get; set; }

Property Value

Type: System.Xml.Schema.XmlSchemaForm
One of the XmlSchemaForm values. The default is XmlSchemaForm.None.


The Form property is set to XmlSchemaForm.Unqualified and a Namespace value is specified.

The Form property determines whether an XML element name is qualified, based on the World Wide Web Consortium ( specification, Namespaces in XML.

If the Namespace property is set to any value, attempting to set the Form property to XmlSchemaForm.Unqualified throws an exception.

The default value, XmlSchemaForm.None, instructs the XmlSerializer to check the schema for the XML document to determine whether the namespace is qualified. For elements, the XmlSerializer checks the value of the schema-element attribute elementFormDefault. For attributes, it checks the value of the schema-element attribute attributeFormDefault. For example, the following XML Schema indicates that the Name element is qualified, while the Number element is unqualified.

 <schema elementFormDefault="qualified" 
    <element name="Name"/>
    <attribute name="Number"/>

Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Windows Phone

© 2016 Microsoft