WebPartGalleryItemBase.InstantiateFromXml method (XmlDocument)

Instantiates a WebPart with the specified XmlDocument.

Namespace:  Microsoft.SharePoint.WebPartPages
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'Declaration
Protected Function InstantiateFromXml ( _
    webPartXml As XmlDocument _
) As WebPart
'Usage
Dim webPartXml As XmlDocument
Dim returnValue As WebPart

returnValue = Me.InstantiateFromXml(webPartXml)
protected WebPart InstantiateFromXml(
    XmlDocument webPartXml
)

Parameters

Return value

Type: System.Web.UI.WebControls.WebParts.WebPart
The instantiated Web Part.

Remarks

This method instantiates and returns a WebPart by using the specified Web Part XML document.

See also

Reference

WebPartGalleryItemBase class

WebPartGalleryItemBase members

InstantiateFromXml overload

Microsoft.SharePoint.WebPartPages namespace