Progress® Telerik® Reporting R3 2017

ReportXmlSerializerSerialize Method (XmlWriter, Object)

Serializes the specified value and writes the XML document to the specified XmlWriter.

Namespace:  Telerik.Reporting.XmlSerialization
Assembly:  Telerik.Reporting (in Telerik.Reporting.dll)

Syntax

public void Serialize(
	XmlWriter writer,
	Object value
)

Parameters

writer
Type: System.XmlXmlWriter
The XmlWriter used to write the XML document.
value
Type: SystemObject
The value to serialize.

Remarks

In the xmlWriter parameter, specify an object that derives from the abstract XmlWriter class. For example you can use the XmlTextWriter class.

Examples

The following example serializes an object using a XmlWriter:
using (System.Xml.XmlWriter xmlWriter = System.Xml.XmlWriter.Create("SerializedReport.xml"))
{
    Telerik.Reporting.XmlSerialization.ReportXmlSerializer xmlSerializer =
        new Telerik.Reporting.XmlSerialization.ReportXmlSerializer();

    xmlSerializer.Serialize(xmlWriter, report);
}

See Also