I\'m using VB.Net I have an url of an image, let\'s say http://localhost/image.gif
I need to create a System.Drawing.Image object from that
You could use WebClient class to download image and then MemoryStream to read it:
C#
WebClient wc = new WebClient();
byte[] bytes = wc.DownloadData("http://localhost/image.gif");
MemoryStream ms = new MemoryStream(bytes);
System.Drawing.Image img = System.Drawing.Image.FromStream(ms);
VB
Dim wc As New WebClient()
Dim bytes As Byte() = wc.DownloadData("http://localhost/image.gif")
Dim ms As New MemoryStream(bytes)
Dim img As System.Drawing.Image = System.Drawing.Image.FromStream(ms)