title: How to download a file from azure blob in Asp.Net core?
body: <p>I'm trying to download an image from azure blob in Asp.Net Core using the below code. But i am getting </p>
  
  <blockquote>
    <p>"The given path's format is not supported"</p>
  </blockquote>
  
  <p>My Code:</p>
  
  <pre><code>StorageCredentials creds = new StorageCredentials(accountName, accountKey);
              CloudStorageAccount account = new CloudStorageAccount(creds, useHttps: true);
              CloudBlobClient client = account.CreateCloudBlobClient();
              container = client.GetContainerReference(blobName);
  </code></pre>
  
  <p>// For download</p>
  
  <pre><code>public async void DownloadAsync(string path, string[] names)
  {
      string MyPath = path.Replace("https://browsercontent.blob.core.windows.net/blob1/", "");
      CloudBlockBlob blockBlob = container.GetBlockBlobReference(MyPath+names[0]);
      path = path + names[0];
      await blockBlob.DownloadToFileAsync(path, FileMode.Create);
  }
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/DfeQz.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/DfeQz.png" alt="enter image description here"></a></p>
  
  <p>How can I resolve this issue?</p>