Displaying logos in report headers conditionally

K

KHogwood-Thompson

Hi All,

I have a report called "INLAND REVENUE RETURN" which includes an image
called "ImageFrame". I need this image to update according to the company
number that is selected via a parameter on the report.

The underlying query has a field from a table called ImageTable, this has
the field for the Company called "CO" and the path to the image called
"ImagePath".

When running the query directly, the correct image path is displayed for the
records chosen via the parameters. When running the report, I get the
folliowing error message:

Run-time error 2465

Microsoft Access can't find the field '|' referred to in your expression

The code that I have for the Report header section on format event is:

Private Sub ReportHeader_Format(Cancel As Integer, FormatCount As Integer)

Me![ImageFrame].Picture = [ZZ INLAND REVENUE RETURN SUMMARY].[ImagePath]


End Sub

Can someone help??
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top