📜  base 64 编码图像到 blob azure - 任何代码示例

📅  最后修改于: 2022-03-11 14:56:53.040000             🧑  作者: Mango

代码示例1
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);
  }