Xml Type property (SDT)

Official Content
This documentation is valid for:
The XML type property allows you to modify the behavior of the XML representation for each item of a structured data type.

Values

Attribute
CData
Element
Value

Description

This property is located at SDT\ItemName\Properties\Xml information section\Xmltype

XML Type Property GeneXus 15

Samples

Consider the following Structured data type:

SDT1
    Item1 Num(4)
    Item2 Char(20)
 

Which is populated throughout the following code:

SDT1
{
   item1 = 1 
   item2 = 'Value'
}

When the Item1 XML type property value is set = "Element", the default value, the SDT XML representation will be as follows:

<SDT1 xmlns="Knowledge Base" >
   <item1>1</item1>
   <item2>Value</item2>
</SDT1>

When the Item2 XML type property value is set = "Cdata", the SDT Xml representation will be as follows:

<SDT1 xmlns="Knowledge Base">
   <item1>1</item1>
   <item2><![CDATA[value]]></item2>
</SDT1>


When the Item1 XML type property value is set = "Value", the SDT XML representation will be as follows: 

<SDT1 xmlns="Knowledge Base" >   
   <item2>Value</item2>
   1
</SDT1>


It is not possible to have more of a "value", by XML node. Otherwise, all values would be concatenated at the end of the node.

When the Item1 Xmltype property value is set = "Attribute", the SDT Xml representation will be as follows:

 

<SDT1 xmlns="Knowledge xmlns="Knowledge Base" Item1="1"> 
<item2>Value</item2>
</SDT1>

See Also

Xml Information Properties (SDT)
XML Name property (SDT)
XML Namespace property (SDT)
Xml SoapType property (SDT)
XML Null Serialization property (SDT)