Link to home
Start Free TrialLog in
Avatar of chan73
chan73

asked on

Store Pictures into TABLE ?

I have created a table named collection.dbf. I hope to store all my pictures into a field named IMAGES. What should I do with the table structure and in the form design?
Avatar of ramrom
ramrom
Flag of United States of America image

For the table:
Create a General Field.
Use Append General to put a picture in the general field.

For the form, from article Q139184:

To display an image on a form from a general field, use an OLE Bound. Set the ControlSource property of the OLE Bound Control to the general field.

Avatar of pforman
pforman

Just to let you know, there will be problems storing pictures in a general field, if you need to use the pictures in other apps (such as Crystal Reports, Word) later.

The recommended procedure is to store the file on disk somewhere, and just store the filename in the table.

PF
and now you know the rest of the story...
If you don't want to use a general field you also can put the pictures in your table. You can store them within  a binary memo field.
APPEND MEMO ... stores a file to the table and COPY MEMO ... gets it.
Won't this make for a VERY large table?  This would not seem to be the best solution to store pictures in a table.  I like the idea of storing the location of the picture.  Of course, if the picture moves, that won't work very well.  Okay, so I am my best enemy in debating!
ASKER CERTIFIED SOLUTION
Avatar of Christof
Christof

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of chan73

ASKER

Answer accepted