add image and data to table

  • Thread starter Thread starter rap43
  • Start date Start date
R

rap43

I need to browse to the image (jpg) and copy it to a know folder. I like the
end user to click the browse button and navigate to the image and then click
copy, the destination folder is known. After clicking copy another form will
launch to add data related to the image to a table. This will add an image
and the data to the database. I like to use a form with a browse and copy
button.
 
I would advise against storing the image in the database, they rapidly chew
up the 2GB available to an Access database.

Instead, just store the file name (and perhaps the path as well). With that
information, you can change set the Picture property of an image control on
your form and don't actually have to store the image in the database.

HTH
Dale
 
Thanks Dale
I am not trying to store the image, the database has up to 500 images that
display from a folder onto a fprm as they are called by the names that are
store in a table. I was hope to have any new image in the same folder and I
can not count on the end user to copy the new images to the correct folder. I
have a form to add data need images in one folder.

Ralph
 
Ralph,

You can use the code shown here (
http://www.mvps.org/access/api/api0001.htm) to select a file. The TestIt
function gives you a great example of how to call the Open/Save dialog API.

Once you get a filename using this API, use the FileCopy command and give it
the directory you want to use, along with the file name as the destination.

HTH
Dale
 
Back
Top