Results 1 to 4 of 4
  1. #1
    Join Date
    Aug 2010
    Posts
    23

    Image in a Report

    Hi everyone. I have a list box displaying multiple items, and am able to print out a report depending on which item is clicked. However, I would like to add a image to each report. In the search query that the report is generated from, the second column is a image path. I have a image frame in my report, and on format I have it following the code listed below.

    Private Sub ImageFrame_Format(Cancel As Integer, FormatCount As Integer)
    Me![ImageFrame].Picture = Me![searchquery]![Column(1)]
    End Sub

    The query that the path is stored in is called searchquery. I think i am messing up my syntax somewhere, can anyone help me out?

    Thanks,
    Sam

  2. #2
    weekend00 is offline I may not be right
    Windows XP Access 2003
    Join Date
    Aug 2010
    Posts
    1,295
    you can put the textbox's name which bound to that column instead of the query name
    Me![ImageFrame].Picture = Me.textboxname

  3. #3
    Join Date
    Aug 2010
    Posts
    23
    Hmm so now I have,

    Private Sub ImageFrame_Format(Cancel As Integer, FormatCount As Integer

    Me![ImageFrame].Picture = Forms![Customer Info Search]![Combo46]![Column(13)]

    End Sub

    The path to the picture is stored in the 14 column in Combo Box 46 on the Customer Info Search form.

    Still no luck :/

  4. #4
    michaeljohnh is offline More Human than Human
    Windows XP Access 2007
    Join Date
    Aug 2010
    Posts
    61
    It would be a bit mickey moused but if there are only a few images you could just hard code the image paths with VB with a Select/Case subroutine.

    Have you tried using the Dlookup command? It works wonders when trying to find an associated field with a changing selection.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Bitmap image
    By FJM in forum Access
    Replies: 1
    Last Post: 06-07-2010, 11:34 AM
  2. Help with image problem
    By alovalto in forum Access
    Replies: 0
    Last Post: 03-15-2010, 08:50 AM
  3. print report on paper for image
    By gromit95 in forum Reports
    Replies: 11
    Last Post: 01-12-2010, 08:09 AM
  4. If statement for image
    By turbo910 in forum Forms
    Replies: 1
    Last Post: 11-30-2009, 04:58 AM
  5. Generate Image
    By dbman in forum Import/Export Data
    Replies: 0
    Last Post: 01-31-2008, 10:46 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums