SchemaImporterExtension.ImportDefaultValue Method (String, String)

 

Allows you to specify the default value for the XSD type being imported.

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

public virtual CodeExpression ImportDefaultValue(
	string value,
	string type
)

Parameters

value
Type: System.String

The value found in the original XSD.

type
Type: System.String

The XSD type name.

Return Value

Type: System.CodeDom.CodeExpression

A CodeExpression setting the new default value.

In order to control the generation of the code, you must use the classes found in the System.CodeDom namespace. For more information, see Using the CodeDOM and CodeDOM Quick Reference.

.NET Framework
Available since 2.0
Return to top
Show: