Need to open a jpeg file and draw it on a webpage (resized) and draw it to a pdf.
dim f as FolderItem = app.userFiles.child(lblLogoFile.text)
dim p as picture
dim i as webImageView = imageLogo
p = picture.Open(f)
imageLogo.picture = p
shows the picture in the imageview, but I can’t seem to resize it.
dim f as FolderItem = app.userFiles.child(lblLogoFile.text)
dim p as picture
p = picture.Open(f)
g.drawPicture(p,0,0)
in canvas.paint does nothing.
help @!!!
Maybe you need to store image in properties so it’s not deleted from memory right away?
Also I would not load images in paint event.
in the webimageview attempt it shows just fine, but can’t find a way to resize it.
I don’t want to load it in paint either.
I only need to show it in a particular container. Don’t need it any other time.
You probably need to have a second picture object of the correct size. If you had for instance p = picture from folder, p2 = picture at correct size then you could use p2.graphics.drawpicture(p, 0, 0, p2.width, p2.height) which will stretch p into p2 then assign p2 to the webimage.
tried that. r = nil
dim p as picture
p = picture.Open(f)
w = 50
h = 100
dim r as picture
r.graphics.drawPicture (p,0,0,w,h,0,0,p.width,p.height)
Dim r As New picture(w, h, 32)
there we go … other problem left me with w = 0. that created a syntax error.
Thanks all.