PDA

Click to See Complete Forum and Search --> : Why can't I load a picture?


SteveCRM
Jan 4th, 2000, 07:01 AM
This won't work!
On Error GoTo PATorJK
CommonDialog1.CancelError = True
CommonDialog1.Filter = "Image Files (*.bmp)|*.bmp"
CommonDialog1.ShowOpen
Open CommonDialog1.Filename For Input As #1
Image1.picture = Input(LOF(1), #1)
Close #1
PATorJK: Exit Sub

It won't open the picture!

Steve

KENNNY
Jan 4th, 2000, 06:24 PM
no ur right it won't, because
Open.. Input.. Close
they cant be used to get binary files, only text files (or any non binary file, eg, u can use open..close for word docs)
anyway, do this:
assuming u've got to the ShowOpen bit..


image1.picture = loadpicture(CommonDialog1.FileName)



------------------
cintel rules :p www.cintelsoftware.co.uk (http://www.cintelsoftware.co.uk)

[This message has been edited by KENNNY (edited 01-05-2000).]