SPWorkflowAssociation.ImportFromXml Method
SharePoint 2010
Creates an SPWorkflowAssociation object from an XML formatted string.
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: Yes
Available in SharePoint Online
Parameters
- rootWeb
- Type: Microsoft.SharePoint.SPWeb
The SPWeb object that contains the BaseTemplate of the association.
- xml
- Type: System.String
An XML string that contains the state of all persisted properties of the association.
Return Value
Type: Microsoft.SharePoint.Workflow.SPWorkflowAssociationThe SPWorkflowAssociation reconstructed from the XML string.
| Exception | Condition |
|---|---|
| ArgumentNullException |
rootWeb is null. |
| ArgumentOutOfRangeException |
xml is null or empty. |