Answers for "base 64 encoded image to a blob azure"

0

base 64 encoded image to a blob azure

CloudBlockBlob cblob = cont.GetBlockBlobReference("testblob");
  var bytes = Convert.FromBase64String(@"iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DHxgljNBAAO9TXL0Y4OHwAAAABJRU5ErkJggg==");// without data:image/jpeg;base64 prefix, just base64 string
  using (var stream = new MemoryStream(bytes))
  {
     cblob.UploadFromStream(stream);
  }
Posted by: Guest on March-04-2021

Browse Popular Code Answers by Language