SALES: 1-800-867-1380

StorageException Class

Updated: April 24, 2013

[This topic is part of the Microsoft Azure Storage Client Library 1.7, which has been deprecated. See Storage Client Library for the latest version.]

The base class for Windows Azure storage service exceptions.

Namespace: Microsoft.WindowsAzure.StorageClient
Assembly: Microsoft.WindowsAzure.StorageClient (in Microsoft.WindowsAzure.StorageClient.dll)

Dim instance As StorageException

public abstract class StorageException : Exception

Based on the source of the error that caused the exception to be thrown, Windows Azure storage services may throw a StorageClientException or a StorageServerException. The StorageException will never be thrown directly. However, it can be difficult or impossible to predict which of the derived exception types will be thrown for an arbitrary piece of code. Regardless, the StorageException base class usually contains sufficient detail regarding the error for you to determine how your application should proceed. Additional guidance regarding how to handle the different exception types can be found in the documentation for the derived classes, StorageClientException or StorageServerException.

    // Storage access code
catch (Microsoft.WindowsAzure.StorageClient.StorageException ex)
    // Inspect ex.ErrorCode or ex.StatusCode for error information
catch (System.Exception ex)
    // General exception handler

When the StorageException is also a StorageClientException exception, additional error details can be found in the ExtendedErrorInformation property. Otherwise, this property is null.

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

Development Platforms

Windows Vista, Windows 7, Windows Server 2008, Windows 8.1, Windows Server 2012 R2, Windows 8 and Windows Server 2012


Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
© 2015 Microsoft