Skip to content
The getting started sample demonstrates how to perform common tasks using the Azure Blob Service in .NET including uploading a blob, CRUD operations, listing, as well as blob snapshot creation.
C#
Branch: master
Clone or download
Latest commit 9483db2 Sep 13, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
BlobStorage fix using statements Jul 9, 2019
.gitignore Updated to latest NuGet packages. May 7, 2019
BlobStorage.sln added advanced samples for blobs Jun 23, 2016
CONTRIBUTING.md Updating repository initial files. Sep 28, 2015
LICENSE Updating repository initial files. Sep 22, 2015
README.md Update README.md Sep 13, 2019

README.md

page_type languages products description urlFragment
sample
csharp
azure
Demonstrates how to use the Blob Storage service.
storage-blob-dotnet-getting-started

Azure Blob Storage Samples for .NET

Demonstrates how to use the Blob Storage service. Blob storage stores unstructured data such as text, binary data, documents or media files. Blobs can be accessed from anywhere in the world via HTTP or HTTPS.

Note: This sample uses the .NET 4.5 asynchronous programming model to demonstrate how to call Azure Storage using asynchronous API calls. When used in real applications, this approach enables you to improve the responsiveness of your application. Calls to Azure Storage are prefixed by the await keyword. For more information about asynchronous programming using the Async/Await pattern, see Asynchronous Programming with Async and Await (C# and Visual Basic).

If you don't already have a Microsoft Azure subscription, you can get a FREE trial account here.

Running this sample

This sample can be run using either the Azure Storage Emulator that installs as part of this SDK - or by updating the App.Config file with your AccountName and Key. To run the sample using the Storage Emulator (default option):

  1. Download and Install the Azure Storage Emulator here.
  2. Start the Azure Storage Emulator (once only) by pressing the Start button or the Windows key and searching for it by typing "Azure Storage Emulator". Select it from the list of applications to start it.
  3. Set breakpoints and run the project using F10.

To run the sample using the Storage Service

  1. Open the app.config file and comment out the connection string for the emulator (UseDevelopmentStorage=True) and uncomment the connection string for the storage service (AccountName=[]...)
  2. Create a Storage Account through the Azure Portal and provide your [AccountName] and [AccountKey] in the App.Config file.
  3. Set breakpoints and run the project using F10.

More information

You can’t perform that action at this time.