Hello all,
I am downloading a picture from website using
URLDownloadToFile(0, img.src, imagenm, 0, 0)
The file is downloaded perfectly and can be opened in mspaint ok
But when i try to set it as picture of picture box control i get error
Invalid Picture
1) If i reopen manually in paint and save it as 16 bit image then i can add it as picture
- can i auto download picture in format which is readable by vb6
i have tried all formats bmp/jpeg/gif
OR
2) If i use following code :
Set O = WebBrowser1.Document.body.createControlRange()
Call O.Add(WebBrowser1.Document.All("mycompanyimagedata"))
Call O.execCommand("Copy")
Set frmcapimg.Picture2.Picture = Clipboard.GetData
All works ok but my webbrowser gives error copy/paste not allowed
is there any other way to set image to clipboard
Thanks in advance as i am new to vb6 any help is very much appreciated
I am downloading a picture from website using
URLDownloadToFile(0, img.src, imagenm, 0, 0)
The file is downloaded perfectly and can be opened in mspaint ok
But when i try to set it as picture of picture box control i get error
Invalid Picture
1) If i reopen manually in paint and save it as 16 bit image then i can add it as picture
- can i auto download picture in format which is readable by vb6
i have tried all formats bmp/jpeg/gif
OR
2) If i use following code :
Set O = WebBrowser1.Document.body.createControlRange()
Call O.Add(WebBrowser1.Document.All("mycompanyimagedata"))
Call O.execCommand("Copy")
Set frmcapimg.Picture2.Picture = Clipboard.GetData
All works ok but my webbrowser gives error copy/paste not allowed
is there any other way to set image to clipboard
Thanks in advance as i am new to vb6 any help is very much appreciated