Display Picture for each Record in Access DB

Yeah, I view my salesman (350 of them) pictures on forms, but I also do mailings to their clients where I need to merge the salesman/client info(including pictures).
So, I would need to export salesman info into a mailing database to send to the print vendor.

I am not currently linking but want to change that but exporting the salesman is a must and must be addressed before I do convert.

Thank you
 
Yea DanG

you can print report of salesman info with picture and send the print to vendor.
 
new image

I didn't realized how you can add new pictures. If you use new picture button it does only change the link of picture shown in subform. I tried to make new record by recordset.addnew but still it changes the picFile selected before add.

any idea?
 
Problem

If I understand, picture can't be in database only external link?
But when I set picture table on OLEObject, I can paste image in database.
Is it possible to nobody have idea for this problem?
 
Embedding the image directly into the db is not recommended as it will seriously slow the performance down as it increases in size.
 
Ok, I know, but I need pictures in DB, and I try to find way for that.
If you know how, pls tell me.
 
Help please

Can you make for me browse button, I try but without effects :mad:
 

Attachments

Thank you

Thank you very much, very much, Oldsoftboss.
btw I have one question, maybe you have solution.
I have over 5000 DVD movies and when I create folder for images,
it is very complicate to find images for this records and folder slowly open
(it is over 5000 images) and last time when I upload all links in DB my hdd was
crashes from another reason. I backup datas from DOS and all images are renames (ex. 12 Monkeys = 12 Mon~) and that's reason why I need pictures in DB. Is it possible that images be in DB or not? I looking on forum without effects.

thanks in advance
zzteam
 
5000 titles. WOW

To have that many images in the Db would bloat it to the max and render it almost unusable. - Tooooo slow

I have the same sort of thing (only about 250 titles) I have a slave HHD on my main PC that I keep all this sort of stuff on. The main HD that will crash is the one with the operating system on it, so hopefully I will be OK.

PS: To add 5000 images / titles etc will take you forever. Good luck

Dave
 
Oldsoftboss

Thank you on answer, Oldsoftboss.
And what is another problem. When I give to my friend catalogue, and when he
copy on HDD, he can't see images (diferent path).

Regards,
zzteam
 
calling a column...

If you have the path to an image in one of the columns on your query results,
C:\blah\blahblah\test.jpg

how would you get the image to be shown for that item...

for example i have a query being displayed in a list called lstnum1...and in column 15 is the path to a picture i want to display. for a textbox i would put...

=lstnum1.column(15) in the control source and it would show exactly that in my textbox how can i get images on my computer to be displayed in the same way?

Cpl Shutts
 
The issue with storing an actual picture in the database, embedded, is that you will RAPIDLY run out of space in Access internal address space. That 2 Gb will dissolve in less than 1000 pictures at today's image densities.

Search this forum for two topics. First, "Image Controls" - we have had many posts on the subject including a couple of my own posts. Second, "Common Dialog" and "OpenFile Dialog" have been posted as well.

So... what you do is build you a database with a field for the file name and path. Usually, if you put the pictures in a folder near the root of your disk, that means shorter paths. 64 characters might be plenty.

Next, build your form. create the image control. You might have to play with the properties for zoom, stretch, etc. But to prevent bloated databases that become impossible to use, DO NOT EMBED YOUR IMAGES.

Ok, still in forms design mode, open the properties for the form itself. Under form events, select the OnCurrent event. The line of code suggested above should go as perhaps the only line of code in the forms.current event. To browse using the OpenFile dialog, you will have a control CLICK event. As the closing line of that event, if the status returned from the control indicates that it selected a file, that file name can be copied to the record. When you store it in the underlying record, also store it in the image control's .picture property and do a me.repaint.

But do the research so you will see the many variations that have been tried and the pitfalls that go with them. This doesn't have to be hard if you keep it simple in terms of goals. Further, once the image referece (file path & name) have been stored once, it is a set-and-forget operation.

In answer to another question, you can have any type of image file for which you loaded that type of image translator when you loaded MS Office. You can RELOAD image handlers - just RELOAD Office and take the Custom option to install extra features. If you have a type of image that Access does not recognize, you might have difficulty. But Access has a pretty darned good set of image handlers.
 
How I got this too work...


i added a column to my table for each item that i wanted to link to a picture. In this column i added a path to the picture i want to come up with the item. I then put a textbox on the form with control source as list1.column(20) --this is the column in the listbox that holds my query results which contains the exact cell with the path to the picture i want to come up. I then made a simple statement in the list1 on click action

If Me.Text1 = "" Then
Me.Image1.Picture = "this image"
Else
Me.Image1.Picture = Me.Text1

this basically just says what to load...if text1 which should be holding information on what picture to load had data load that path...if not then load a default picture or none at all.


i then put under the text1_change action
Me.Image1.Picture = Me.Text1

telling it to change the picture if the data in the textbox changes.. meaning if someone clicks on a differnt query result in my listbox the picture will go along with the data that is changing.

I then just hide the textbox and it was good to go.


Pretty easy and it allows you to keep your DB small as possible.

Take care.

Semper Fi


Cpl Shutts
 
About 'movie' zip

Gentlemen! It’s so addictive to work on database, it’s like a puzzle for me, because I have never tried it before… i thought I accomplished everything, but I discover everyday something to fix – and that is fun too… 
I downloaded ‘movie’ zip from rahulgty - thank you!, and that it exactly what I need, buttons to add photos and remove them. that would be the last step in my database creation, I didn’t expect actually to have problem with it… but I have this error –‘you cannot assign a value to this object’…
I wonder how it’s supposed to work…?
Thank you to everybody…
 
Check the field names. If] you copied# this code from another Db ~ you will get this error if the code cant find the correct field name,(
 

Users who are viewing this thread

Back
Top Bottom