Hallo, wie kann ich bei einer ImageWell ein Bild aus einer Url laden ? Also bei VB:
Picturebox1.ImageLocation = "https://www.gravatar.com/avatar/87dc161da10f6ea4df35cdbd5dc0d289?d=identicon&s=128"
Mfg VBWorld
Hallo, wie kann ich bei einer ImageWell ein Bild aus einer Url laden ? Also bei VB:
Picturebox1.ImageLocation = "https://www.gravatar.com/avatar/87dc161da10f6ea4df35cdbd5dc0d289?d=identicon&s=128"
Mfg VBWorld
Desktop oder Web?
Die Antwort hngt davon ab.
Desktop auf dem Mac
Nimm ein HTTPSocket und lad das Bild.
Wenn du’s hast, dann Picture.FromData.
So lade ich das bild herunter:
DIM WC AS NEW HTTPSocket
WC.Get()
Aber wo muss ich jetzt den Parameter zum Speicherort setzen
ungefhr so
dim h as new httpsocket
dim data as string = h.get(url, 30)
imageWell1.backdrop = Picture.FromData(Data)
Warum wird eine Datei als String deklariert ?
Es ist keine Datei, solang du es nicht als solche abspeicherst. Bis dahin sind es nur Daten im Zwischenspeicher - deshalb String.
man kann natürlich auch mit Get Direkt in ein Folderitem laden lassen.