Problem with image upload

  • Thread starter Thread starter gudiya
  • Start date Start date
G

gudiya

Hi,

I need urgent help for uploading(browsing etc) . jpg or .bmp images in
the table for each record through the form using a command
button.Please help
 
I don't recommend that you store the pictures in the database. It will make
the database grow very quickly. The usual solution is to leave the picture
in a folder and just store the path to them in the database. Then you can
load the picture into a form or report programmatically at run-time. On my
website (www.rogersaccesslibrary.com), is a small Access database sample
called "PicturesLoad.mdb" which illustrates how to do this.

--
--Roger Carlson
MS Access MVP
Access Database Samples: www.rogersaccesslibrary.com
Want answers to your Access questions in your Email?
Free subscription:
http://peach.ease.lsoft.com/scripts/wa.exe?SUBED1=ACCESS-L
 
Hi,

As Roger Carlson said, putting images into database will grow database very
quickly, but there are some occasion that Images are better inserted into
databases for ease of management.

I am not sure in what particular situation you are in right now?

If you want to insert images into databases then this link will help you :

http://support.microsoft.com/default.aspx?scid=kb;en-us;194975
How To Read and Write BLOBs Using GetChunk and AppendChunk

And your table field for holding your images should be OLE Object.

so choose the best method that you think will be best for your particular
situation.
 
Hi,I tried to implement as it is in PicturesLoad.mdb project but i am
facing a complie error
" sub or function not defined" at this line.
strFilter = ahtAddFilterItem(strFilter, "Picture Formats (*.jpg *.jpeg,
*.bmp, *.gif)", "*.jpg; *.jpeg; *.bmp; *.gif")

what should i do to remove this error.Please help
 
Thanks a lot.Now the form is working.
But now I have problem with report.
Previously,i had an OLE object field to store images in the
database.but now i have a text field which stores link to the images
for each record.My report had a bound object frame to display image for
each record.Now I want to display the image stored as link in the text
field of the database.Wat should I do or change to display the image
from the link stored in the databse through the form.
Please help.
 
gudiya said:
I need urgent help for uploading(browsing etc)
.jpg or .bmp images in the table for each record
through the form using a command button.
Please help

The sample imaging databases at http://accdevel.tripod.com illustrate three
approaches to handling images in Access, and the download includes an
article discussing considerations in choosing an approach. Two of the
approaches do not use OLE Objects and, thus, avoid the database bloat, and
some other problems, associated with images in OLE Objects. In fact, based
on your description, you might even be able to use the example database as
the start of your application.

If you are printing the images in reports, to avoid memory leakage, you
should also see MVP Stephen Lebans' http://www.lebans.com/printfailures.htm.
PrintFailure.zip is an Access97 MDB containing a report that fails during
the Access formatting process prior to being spooled to the Printer Driver.
This MDB also contains code showing how to convert the contents of the Image
control to a Bitmap file prior to printing. This helps alleviate the "Out of
Memory" error that can popup when printing image intensive reports.

Larry Linson
Microsoft Access MVP
 
Back
Top