Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Import a Picture

Status
Not open for further replies.

Chalco

Programmer
Jul 17, 2003
32
GB
Hi,

Can anybody help - I don't know where to start - I would like to add a button onto my my form, which calls up a dialogue box to select a picture to import, and then store this in the database (I have an object on the form called, Photograph (oddly enough !!))

I have read the fact that the database size will increase significantly, but I would still like to do it.

I have managed to get by so far by right hand clicking and importing an object, but for people who are not "Computer Literate" I would like to make the screen more friendly ( I don't know if my wife will like me descibing her in such a manner thou' ;o) !!)

Also, is there an easy way to resize the object at the time of import (as the photo field will allow a max of 520x310 pixels - at the moment, I am using some freeware which will resize to a given size, but again, it is a bit much for my wife to cope with.

Richard
 
I would recommend you reconsider the technique of actually importing and saving a picture in your database. It is far more effecient to just store the path to the picture in the Picture ofject of a form or report and have it retrieve it for display as needed. This can be done quite easily. I have included a thread that I answered quite some time ago that details how to do this for both a form and a report. Hopefully, it will give you some inside as to how to set this up for your circumstances.

thread702-289543

Post back if you have any questions.

Bob Scriver
Want the best answers? See FAQ181-2886
Nobody believes the official spokesman... but everybody trusts an unidentified source.
Author, Bagdad Bob???

 
Thanks Scriverb (Sorry for the delay, but I have been off on Holiday/Vacation) - I will implement that for the majority of the images, however, there is one bit where I allow the user to import a logo for the reports - this is only a very small image - I know I could amend all my code to allow this, but can you point me in the right direction to get the logo physically imported into the database via a button ?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top