title: Get azure container blob contents using powershell
body: <p>I am trying to get the azure container blob contents using Powershell.</p>
  
  <p><strong>Code</strong></p>
  
  <pre><code>$Ctx = New-AzStorageContext -StorageAccountName abc -StorageAccountKey 'xxxx=='
  $latestBuild = Get-AzStorageBlob -Context $Ctx -Container jmeter -blob "Script\Load1"
  if($latestBuild -ne $null)
  {
      foreach($item in $latestBuild)
      { 
          Get-AzStorageBlobContent -Blob $item.name -Container jmeter -Destination C:\ -Context $Ctx -Force
      }
  }
  else
  {
      write-host "Blob is empty !!!"
  }
  </code></pre>
  
  <p><strong>Error</strong></p>
  
  <pre><code>Get-AzStorageBlob : Can not find blob 'Script\Load1' in container 'jmeter', or the blob type is unsupported.
  At line:2 char:16
  + ... testBuild = Get-AzStorageBlob -Context $Ctx -Container jmeter -blob " ...
  +                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      + CategoryInfo          : ObjectNotFound: (:) [Get-AzStorageBlob], ResourceNotFoundException
      + FullyQualifiedErrorId : ResourceNotFoundException,Microsoft.WindowsAzure.Commands.Storage.Blob.Cmdlet.GetAzureStorageBlobCommand
  
  Blob is empty !!!
  </code></pre>
  
  <p>There are two files present in the Load1 folder :</p>
  
  <p><a href="https://i.stack.imgur.com/EFaWY.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/EFaWY.jpg" alt="enter image description here"></a></p>