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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Listbox Field to grab OLE objects from another table

Status
Not open for further replies.

IcePak

Technical User
Nov 7, 2001
23
US
Hi,
I have one main table with 150 entries. I have another table with 6 entries. This second table is just one field of OLE objects (metafile images).

Each entry in my main table is associated with 1 of 6 images (the OLE images stored in the second table). I want to have a field in my main table that is a drop-down listbox containing the 6 OLE records of my second table.

This OLE information is displayed alongside some main table info on a report. I've tried a bunch of different ways, but the only way I managed to get the Report to display the picture is by copying thecorresponding (of 6) OLE objects from the second table into the main table. (this meant copying and pasting some 50 times). It worked though, but my database is now 350 MB as opposed to the 10MB it was before. There's got to be a way to have the field in the main table referencing the 6 from the second table, but in a FOOLPROOF manner. I could swear I did it correctly, but the image wouldn't appear on the report.

I just to have 6 images saved to my database, not 150 ones that are really just those 6 copied and pasted.

Maybe someone knows what I did wrong on the report or in the linking.
PLEASE HELP

thanks
Mike
 
Hi Mike!

Create relationship between your Table1 and Table2(image tbl). If Table2 isn't contained any ID field (number or text type) then create it (primary key). Add field also to Table1 for saving Image ID. Now you may only save ID of needed image from Table2 in the Table1. For report create query which include data from Table1 and OLE field from Table2.

Aivars
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top