hawk1ns Posted July 13, 2003 Posted July 13, 2003 Hello Guys.. I would like to create a small windows based program that grabs images/info from a website.. i have some things sorted but i dont know how to grab the graphics side ? how can i load an image into a picturebox from a web address ? i have tried : picturebox1.image.fromfile("www.domainname.com/images/gfx.gif") but i get an error , i know that i can use this to display an image from my pc but how do i do this from web? Regards Carl Quote
*Experts* mutant Posted July 13, 2003 *Experts* Posted July 13, 2003 You can do it using the WebClient class: Dim dl As New Net.WebClient 'create new instance dl.DownloadFile("http://www.youraddress.com/image.gif", "C:\image.gif") 'download the file using DownloadFile method to a specified path p.Image = Image.FromFile("C:\image.gif") 'load the image from the path you downloaded it to :) Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.