locked
Report Viewer Image Control RRS feed

  • Question

  • User1384525187 posted

    Hi all,

    I can't figure out how to display a dynamic image using the Image control. I've a database table that holds image information, including an address to the image on the server. ex: \\ServerName\x$\ImageDir\Header.jpg

    I've tried to set the Source to External and the Value to Fields!vcPictureLocation.Value (field for the address above) in the Properties panel, but the images appear as broken symbols. Does anyone know how to accomplish this?

    As always any help is greatly appreciated. Thanks!

    Thursday, November 8, 2007 8:42 AM

Answers

  • User-175177222 posted

    msnyder,

    The way i have done it..

    Drag the image control to your report.. when the wizard pops  up.

    Select database as the option ,, Specify ur fields in the database and the mime type associated with in... and

    Once that is done.. select the image and set its source to external and then it should work...

    while ur saving the link to the database make sure its set as  http://servername/Applicationname/anyfolders/filename

    hope it helps

    Regards

    KAren

     

     

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, November 8, 2007 10:07 AM
  • User1384525187 posted

    they are on a report server.

    i actually found the solution. there were 2 important details, the first was the steps you outlined about how to set up the image in the report viewer. that solved problem #1. problem #2 was that anonymous access needed to be enabled. the option to enable it was in iis in the project properties.

    thanks for the help!

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Friday, November 30, 2007 3:30 PM

All replies

  • User-175177222 posted

    msnyder,

    The way i have done it..

    Drag the image control to your report.. when the wizard pops  up.

    Select database as the option ,, Specify ur fields in the database and the mime type associated with in... and

    Once that is done.. select the image and set its source to external and then it should work...

    while ur saving the link to the database make sure its set as  http://servername/Applicationname/anyfolders/filename

    hope it helps

    Regards

    KAren

     

     

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, November 8, 2007 10:07 AM
  • User1384525187 posted

    KAren, thx for the reply. I was able to get the image working locally using your method. However, when I deploy the report onto the server the images are still not displaying. I viewed the source of the report viewer and it says IMG SRC="" for all of the images.

    As a test, I dragged an image object onto the report, set it equal to a web source, put in the same URL as what's being pulled from the database. Worked fine locally when I previewed the report, but it would not display once deployed.

    I followed your steps exactly and also changed the link thats being stored in the database to your format. Any ideas? Thanks a lot!

    Tuesday, November 20, 2007 9:24 AM
  • User-175177222 posted

    ok.. where are ur images located???

    Wednesday, November 21, 2007 5:09 PM
  • User1384525187 posted

    Very sorry for the delay...

    I actually made a new directory called 'Pictures" located in my website project directory. I am storing the images there. The URL I'm storing in the database looks like this...

    http://SERVER/safetyforms/Pictures/0d8a3ee0-ee01-48d4-baba-b408a573e1b3.jpg

    The image displays in the report viewer when I click the preview tab, but won't display when I publish it. Shows IMG SRC="" in the cource code.

    Friday, November 30, 2007 1:41 PM
  • User-175177222 posted

    are u reports stored in a report server or are they local reports

     

    Friday, November 30, 2007 2:45 PM
  • User1384525187 posted

    they are on a report server.

    i actually found the solution. there were 2 important details, the first was the steps you outlined about how to set up the image in the report viewer. that solved problem #1. problem #2 was that anonymous access needed to be enabled. the option to enable it was in iis in the project properties.

    thanks for the help!

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Friday, November 30, 2007 3:30 PM
  • User1134808855 posted

    I have the same problem!

    but i do not solve the problem!

    can you detail the solution to me?

    Tuesday, December 18, 2007 12:22 PM
  • User1384525187 posted

    Nanim,

    Follow Karenros instructions for setting up the image in the report viewer. Make sure the pictures are being stored in a subdirectory of your main project (ex. root/Pictures) Then, go into IIS and set the permissions for the Pictures folder to anoymous. The option should be in the project properties.

    The one mistake I made was setting the entire project to anoymous. We just want the pictures directory to be anoymous.

     

    Wednesday, December 19, 2007 11:22 AM
  • User480196582 posted

     Please help me.   I am stuck.  I cannot display the image in ReportViewer using Database Image Field.  I can only see general, visibility and .  How do  I do it.?

    Saturday, February 28, 2009 9:29 PM
  • User-175177222 posted

    You can see the Mime Type and source in the Data section of image... Go to SSRS open the project and hit F4 and u will get the properties window... you can then change the mime type and source of the image.

    Tuesday, March 3, 2009 1:19 PM