WorkflowMarkupSerializer.Serialize Method (XmlWriter, Object)

 

Serializes the specified Object into a workflow markup file or stream.

Namespace:   System.Workflow.ComponentModel.Serialization
Assembly:  System.Workflow.ComponentModel (in System.Workflow.ComponentModel.dll)

public void Serialize(
	XmlWriter writer,
	object obj
)

Parameters

writer
Type: System.Xml.XmlWriter

An XmlWriter that contains the stream or file used in serializing.

obj
Type: System.Object

The object to be serialized.

Exception Condition
ArgumentNullException

writer is a null reference (Nothing in Visual Basic).

ArgumentNullException

obj is a null reference (Nothing).

You must serialize either a new instance of a workflow type or the root activity in a programmatically-created workflow to create workflow markup that can be used in CreateWorkflow to create a WorkflowInstance.

For more information about workflow markup, see Using Workflow Markup.

.NET Framework
Available since 3.0
Return to top
Show: