load image to database

  • Thread starter Thread starter Souris
  • Start date Start date
S

Souris

I need to add picture in to my database.

What's type of field I need create in the table?
Do I need any function to add this in my app to add pictures in to my app?

Your information is great appreciated,
 
Do not put images in your database. Access has a size limit of 2gb. With
images, you can blow this limit easily.

The better way to do it is create a directory where your images will be
stored and use a text or hyperlink field in a table to point to the image
location.
 
Thanks for the information,

I just need to have a hyperlink like \\server\myapp\picture\mypicture to
different locations for the field. MS Access will load the image to bound
image frame?

Thanks again,
 
you will need the field that holds the path to the image in your form's
record source. Put the name of the field in the Control Source property of
the bound object frame control.
 
Is it file name or path?
If it is path then what happens that I need have picture in every record?
Can Access know which file I need for this record?

Thanks again,
 
I have MyIcon field in MyTable. MyIcon field type is HyperLink.
I have a form with bound image frame.
The form data is MyTable and Bound image frame source is MyIcon.
The data is C:\MyPicture\Picture.jpg.

The image does not show on my bound image frame.

Can y ou please advise what I should check or where I am wrong on this?
Your information is great appreciated,
 
If I use image control and add a line of code on form.current like following

Me.image.picture = "C:\MyPicture\picture.jpg" which works.

If I use frame bound object then it does not show the picture.

I have my path in the field and bound frame object link the field, but I do
not get picture.

Any thing I have look?

Your information is great appreciated,
 
It looks that the calling function pass the value of the control instead of
control itself.
The called function look get the value, but nnot control.
When the called function validate the control type then get object required,
since it is value or string which is not control.
 
It looks that the calling function pass the value of the control instead of
control itself.
The called function look get the value, but nnot control.
When the called function validate the control type then get object required,
since it is value or string which is not control.

I never use bound object frame controls for images.
Just as you discovered, in the Current event, set the picture property
of a simple image control to the path which is stored a simple text
field in the table.
The image control can be in a report just as well as a form.
Maybe I'm missing something here but the only reason I can think of
using a hyperlink is if you need to edit the image outside of Access.
You don't need it for just showing the image.
David Stelle, Access App Developer
 
Thanks for the message

david12 said:
I never use bound object frame controls for images.
Just as you discovered, in the Current event, set the picture property
of a simple image control to the path which is stored a simple text
field in the table.
The image control can be in a report just as well as a form.
Maybe I'm missing something here but the only reason I can think of
using a hyperlink is if you need to edit the image outside of Access.
You don't need it for just showing the image.
David Stelle, Access App Developer
 
Back
Top