Share via


WebPartMobileAdapter.OnUnload method

Replaces the OnUnload(EventArgs) method of the control that is being adapted.

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

Syntax

'Declaration
Protected Overrides NotOverridable Sub OnUnload ( _
    e As EventArgs _
)
'Usage
Dim e As EventArgs

Me.OnUnload(e)
protected override sealed void OnUnload(
    EventArgs e
)

Parameters

Remarks

This method does not derive from the OnUnload(EventArgs) method of the control that is being adapted, but it “overrides” it in a broad sense because, when there is an adapter for the current browser, the adapter’s OnUnload(EventArgs) method is called, not the control’s. The control’s OnUnload(EventArgs) method, however, is called indirectly by the adapter’s.

If the control is on a mobile Web Part page, this override will call OnUnloadForMobile(EventArgs). If the control is not on a WebPartMobilePage, this override simply calls the base adapter class’s OnUnload(EventArgs).

See also

Reference

WebPartMobileAdapter class

WebPartMobileAdapter members

Microsoft.SharePoint.WebPartPages namespace