disposing system.image.fromfile() object
OK, I am loading a jpg into a picture box using...
Code:
picturebox.image = image.fromfile("temp.jpg")
I then clear the image...
Code:
picturebox.image = Nothing
I now want to delete the file "temp.jpg" but I get an exception stating that the file is currently in use. Im guessing that the object created by system.image.fromfile() still has its grasp on the file I want to delete. How do I get it to let go. Disposing of the picturebox control doesn't help. I have no way of referencing the object created by the system, (or at least that I know of...) any ideas. Thanks.
-scuz