I'm still not getting it. I tried the code above (with the changes I think I'm expected to make) and it does not give me a result (no blobItems). I tried with no slash, front and back also.
Also, I don't know the name of the subdirectory ("mydir1"). That is what I need to iterate for, even if the example did work, it does not give me a hint on how to get that name.
private void buttonListContainer_Click(object sender, EventArgs e)
{
CloudBlobClient cloudBlobClient = _storageAccount.CreateCloudBlobClient();
CloudBlobDirectory topLevelDirectory =
cloudBlobClient.GetBlobDirectoryReference(
"https://peterstest.blob.core.windows.net/3-6469723158585858?restype=container&comp=list");
CloudBlobDirectory subDirectory = topLevelDirectory.GetSubdirectory("/mydir1");
IEnumerable<IListBlobItem> blobItems = subDirectory.ListBlobs();
foreach (IListBlobItem blobItem in blobItems)
{
Uri uri = blobItem.Uri;
}
Peter Kellner http://peterkellner.net Microsoft MVP • ASPInsider