In Reporting services, how do I add an image from a string or cell in the table?
What I'm trying to do is this: I have a string with the full path to the image. I tried to add an external image to my report and set the image source to my string. but every time I load the report, it doesn't load the image. How do I do this, or is there a better way of doing this?
开发者_Python百科Thank you
For an External image, the image source needs to be a URL for the image. Reporting Services will try to get the image using anonymous access.
http://technet.microsoft.com/en-us/library/dd220527.aspx
Ok, I got it figured out. What I did was in the image properties, in the General Tab, I selected the image source as External, I then created a report parameter Called "@ImageURL", and selected it in the "Use this image:". On the form I added this line of code: ReportViewer1.LocalReport.SetParameters(New Parameter("ImageURL", string.concat("file:\","C:\ImagesFolder\ImageName.jpg"))) this brings up the image correctly.
精彩评论