473,395 Members | 1,624 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Photos in Deatil Section of Reports

I have a parent table - we'll call it SignOwners. It has various info about a bunch of sign owners.
I have a child table that contains information about each sign these people own. Among that information is a filename that contains a photo of the subject sign.

Now I want to put out a report that is organized by Owners and has a detail of each sign they own, including a photo of it.
So I have my parent "Owner" report and a subreport for the individual signs. Simple enough. No problems with any of this, except getting the photos to appear in the detail sections of the child report.
I've tried bound object frames, which I thought would do the trick but I just get empty boxes. I tried using Images, but I can't figure out how to reset the ".picture" property for every occurance.

I thought this would be real simple and straightforward to do. Is there some fundamental concept or method I'm missing?
Dec 3 '07 #1
2 1283
ADezii
8,834 Expert 8TB
I have a parent table - we'll call it SignOwners. It has various info about a bunch of sign owners.
I have a child table that contains information about each sign these people own. Among that information is a filename that contains a photo of the subject sign.

Now I want to put out a report that is organized by Owners and has a detail of each sign they own, including a photo of it.
So I have my parent "Owner" report and a subreport for the individual signs. Simple enough. No problems with any of this, except getting the photos to appear in the detail sections of the child report.
I've tried bound object frames, which I thought would do the trick but I just get empty boxes. I tried using Images, but I can't figure out how to reset the ".picture" property for every occurance.

I thought this would be real simple and straightforward to do. Is there some fundamental concept or method I'm missing?
I have very little information to work on, so I made several Assumptions. You will have to make the necessary substitutions yourself. Place similar code in the Format() Event of the Detail Section on the Sub-Form. Each specific Graphic Image associated with a sign will then be loaded into the Image Control for each Record in the Sub-Form:
Expand|Select|Wrap|Line Numbers
  1. Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
  2. On Error Resume Next
  3. 'Assumptions
  4. '   1) Image Control on Sub-Form named imgPicture.
  5. '   2) Child Table is named tblChild.
  6. '   3) An ID Field that uniquely identifies a Record in tblChild is named [PhotoID].
  7. '   4) This [PhotoID] Field exists on the Sub-Form and is called txtPhotoID.
  8. '   5) The [PhotoID] Field in tblChild is a Numeric Data Type.
  9. '   5) The [filename] Field exists in tblChild and contains the Fully Qualified
  10.       'Path to the Graphic Image for each sign.
  11.  
  12. Me![imgPicture].Picture = DLookup("[filename]", "tblChild", "[PhotoID]=" & Me![txtPhotoID])
  13. End Sub
Dec 4 '07 #2
Thanks. Using the 'Detail_Format' event was the key. I was actually able to get it to work with the following:
Me![imgPicture].Picture = Me![FileName]
Dec 5 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Chris Hartnell | last post by:
I have an Access 2003 database that has a text field which contains a path to a photo. Each new page of the report links to and displays the photo. I use the following code: Private Sub...
6
by: Steve Jorgensen | last post by:
I tried to fix a problem for a client today in which report sections and even individual text controls in some of their reports are being split across page boundaries. Of course, I was thinking...
3
by: Dirk Goossens | last post by:
Hi! I stored the file name and path of photos in a table with data from students and teachers. Is there a way to show the photos in a report or form? Thanks! Dirk Goossens Vrij Instituut...
7
by: Eric Lindsay | last post by:
I would like to do a photo gallery with a liquid layout. I wanted to center a caption below each photo (or above each photo). I can do that easily with tables, but then I don't have a liquid...
1
by: gm | last post by:
Hi; I have written a database that tracks all the installation we have ever done. I have a small heating company. I have recently started keeping a directory of digital photographs of the...
2
by: el_espasmo | last post by:
Yes... I know the question might be stupid but... I still want to try because I haven't been able to solve this. I have been trying to change some stuff in MySpace, but not in my profile, in...
0
by: el_espasmo | last post by:
Yes... I know the question might be stupid but... I still want to try because I haven't been able to solve this. I have been trying to change some stuff in MySpace, but not in my profile, in...
4
by: lorirobn | last post by:
Hi, I need to add photos to my database. Back End is on MS SQL Server (I believe 2000), and Front End is on MS Access. I have read about storing the photos as BLOBS, but I am not sure how to...
10
by: sara | last post by:
Hi - Is it possible to hide the detail section of a report at run time? I have a report that prints all details, with summary lines. The user would like the report ALSO with just summary lines....
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.