Load an image from a url into a PictureBox

 

var url="https://xyk.cebbank.com/verify_code.jpg?3345789";

HttpClient client = new HttpClient();

Bitmap bitmap = null;
var stream = client.GetStreamAsync(url).Result;
bitmap = (Bitmap)Image.FromStream(stream);
this.PictureBox.Image = bitmap;

posted @ 2016-08-31 13:58  zzhi.wang  阅读(219)  评论(0)    收藏  举报