Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Adding an image to individual records

Status
Not open for further replies.

Phreeneazie

Technical User
Apr 6, 2003
27
GB
Hi,

hoping someone can help...

I am writing a database for a car club. Each record will contain all the details of each individual member. I've written everything and it all works fine (first time I've ever written a dbase and I'm quite pleased with it!) The only thing I don't know how to do (and I have tried and tried and searched for hours!) is add a picture of each members car to their own record...What I want, is the person who does the data entry to be able to do this:

"First name" (data entry keys in first name)
"Surname" (data entry keys in surname)
etc., etc., etc., and then finally:

"Members car" (data entry then navigates to a file on the harddrive and selects an individual image).

If anyone can help, I'd be eternally grateful!

Many, many thanks in advance.
 
Members Car would be an OLE field type in your table.

Then in your form, place a bound OLE control.

When you right-mouse click in it, you can select Insert Object, then select Create From File, then click on Browse to locate the file.

You could create a command button that automates this somewhat.

In the button's Click event:

Me!Members_Car.SetFocus
DoCmd.RunCommand acCmdInsertObject

Hope this helped!

Anthony J. DeSalvo
President - ScottTech Software
"Integrating Technology with Business"
 
That button works great!! Thanks

The only problem i have now is that the image only dsiplays as an Icon?? Even when i have unchecked the display as icon tick box??

Any help would be greatly appreciated.

Thanks
 
Hi,

thanks for the help so far...I tried the Bound OLE and it worked on the right-click as you described, but when I added the first image, I skipped to the next record and it had the same image..??? I tried the Command Button but have no experience in how to do this so after trying a few times, gave up. Anymore advice greatly appreciated!

Thanks.
 
Correction!

I have now realised my mistake - I didn't set the OLE up in my table! It works brilliantly now...Many, MANY THANKS!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top