Condividi tramite


DataFormWebPart.HandleGeneralException Method

Handles general exceptions.

Namespace:  Microsoft.SharePoint.WebPartPages
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: No

Syntax

'Declaration
Protected Overridable Function HandleGeneralException ( _
    e As Exception, _
    <OutAttribute> ByRef msg As String _
) As Boolean
'Usage
Dim e As Exception
Dim msg As String
Dim returnValue As Boolean

returnValue = Me.HandleGeneralException(e, _
    msg)
protected virtual bool HandleGeneralException(
    Exception e,
    out string msg
)

Parameters

  • msg
    Type: System.String

    When this method returns true, contains a string that represents the message for the exception; when this method returns false, contains an empty string. This parameter is passed uninitialized.

Return Value

Type: System.Boolean
true if the exception was handled; otherwise, false.

Remarks

This virtual method recursively checks e and its inner exception until finding an Exception whose type is expected, and then sets the msg according to the type of the Exception.

See Also

Reference

DataFormWebPart Class

DataFormWebPart Members

Microsoft.SharePoint.WebPartPages Namespace