SPException Class

Represents an exception in Microsoft SharePoint Foundation.

Inheritance Hierarchy

System.Object
  System.Exception
    System.ApplicationException
      Microsoft.SharePoint.SPException
        

Namespace:  Microsoft.SharePoint
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: Yes
Available in SharePoint Online

Syntax

'Declaration
<SerializableAttribute> _
Public Class SPException _
    Inherits ApplicationException
'Usage
Dim instance As SPException
[SerializableAttribute]
public class SPException : ApplicationException

Remarks

The SPException class is generally used to indicate a violation of a requirement in SharePoint Foundation. For example, attempting to delete the site template gallery creates an exception.

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also

Reference

SPException Members

Microsoft.SharePoint Namespace

Inheritance Hierarchy

System.Object
  System.Exception
    System.ApplicationException
      Microsoft.SharePoint.SPException
        Microsoft.SharePoint.SPContentTypeReadOnlyException
        Microsoft.SharePoint.SPContentTypeSealedException
        Microsoft.SharePoint.SPDistributionGroupException
        Microsoft.SharePoint.SPDuplicateValuesFoundException
        Microsoft.SharePoint.SPEndpointAddressNotFoundException
        Microsoft.SharePoint.SPExternalApplicationRegistrationException
        Microsoft.SharePoint.SPFeatureDefinitionMissingException
        Microsoft.SharePoint.SPFeatureDependencyNotActivatedException
        Microsoft.SharePoint.SPFeatureIsOrphanedException
        Microsoft.SharePoint.SPFeatureUpgradeFatalErrorException
        Microsoft.SharePoint.SPFeatureUpgradeInformativeWarningException
        Microsoft.SharePoint.SPFieldValidationException
        Microsoft.SharePoint.SPFieldValueException
        Microsoft.SharePoint.SPFileCheckOutException
        Microsoft.SharePoint.SPFileLockException
        Microsoft.SharePoint.SPInvalidLookupValuesException
        Microsoft.SharePoint.SPInvalidPropertyException
        Microsoft.SharePoint.SPListDataValidationException
        Microsoft.SharePoint.SPQueryThrottledException
        Microsoft.SharePoint.UserCode.SPUserCodeExecutionPipelineFailedException
        Microsoft.SharePoint.UserCode.SPUserCodeExecutionPipelineTerminallyFailedException
        Microsoft.SharePoint.UserCode.SPUserCodeNoAvailableServersFoundException
        Microsoft.SharePoint.UserCode.SPUserCodeSolutionExecutionFailedException
        Microsoft.SharePoint.UserCode.SPUserCodeValidationFailedException
        Microsoft.SharePoint.WebPartPages.DataSourceControlDisabledException