Adding an Image to a Report
An image is a report item that contains a reference to an image that is stored on the report server, embedded within the report, or stored in a database. An image can be a logo or picture, or it can be a picture that is repeated with rows of data. You can also use an image as a background for certain report items.
When you use a server-based image in a report, the image item contains a path that points to an image on the report server. This image can be one that already exists, or you can publish image files to a report server from a project in Report Designer. (Within Report Designer, these images are known as project images.) When you use an embedded image, however, the image data is stored within the report definition and does not exist as a separate file.
Server-based images work well for logos and static pictures that are shared among several reports or Web pages. Embedded images ensure that the images are always available to the report, but they cannot be shared. Report definitions with server-based images are smaller than definitions with embedded images.
Data-bound images can also be displayed from binary data stored in a database. For example, the pictures that appear alongside product names in a product list are database images.
Making an image available to a report is not the same as adding it to the report layout. To put an image on the report, drag the Image control from the toolbox to the report. Dropping an image onto the report layout starts the Image Wizard. You can continue with the Wizard to specify the source of the image, or you can cancel the Wizard and specify the source property.
To view instructions about adding an image to a report, see How to: Add an Image (Image Wizard).
Embedding Images
You can embed images in a report so that all image data is stored within the report definition. When you embed an image, Report Designer MIME-encodes the image and stores it as text in the report definition. Using an embedded image ensures that the image is always available to the report, but it also increases the size of the report definition.
To view instructions about embedding an image, see How to: Embed an Image in a Report (Report Designer).
External Images
You can include stored images in a report by specifying a URL to the image. When you use an external image in a report, the image source is set to External and the value for the image is the URL address to the image. For a report published to a report server configured for native mode, use a full or relative path. For example, http://<servername>/images/image1.jpg. For a report published to a report server configured in SharePoint integrated mode, use a fully qualified URL. For example, http://<SharePointservername>/<site>/Documents/images/image1.jpg.
When the report is previewed in Report Designer, preview uses the credentials of the user to display the image. When the report is run on the report server, the report server uses the unattended execution account to retrieve the image. If the unattended execution account is not specified, the image is retrieved using no credentials (anonymous user account). If either of these accounts have insufficient rights to access the image, the image will not be displayed in the report. For more information about the unattended execution account, see Configuring an Account for Unattended Report Processing.
To view instructions about adding an external image to a report, see How to: Add an Image (Image Wizard).
Project Images
You can store images in the report project. When the reports in the project are published, the images are also published to the same location. Images are published to a report server as resources. Once the image is published, you can update it and republish it to the report server just as you would any other resource. Reports that include the image use the updated version automatically, without having to republish the report itself. You may need to refresh the report to view an updated image.
When you use a project image in a report, the image source is External and the value for the image is the name of the image, using a relative URL path (for example, Image1.jpg).
To view instructions about adding a project image, see How to: Add an Image to a Project (Report Designer).
Background Images
You can use an image as a background image in the body of the report or in a rectangle, text box, list, matrix, or table. A background image has the same properties as an image. You can also specify how the image is repeated to fill the background of the item.
Note
Some rendering extensions, like the HTML rendering extension, render the background image for the report body in the body, the page header, and the page footer. You can define a separate background image for the page header and footer, but if no image is defined, the report uses the background image of the body. Other rendering extensions, like the Image rendering extension, do not render the body background image in the page header and footer.
To view instructions about adding a background image, see How to: Add a Background Image (Report Designer).
Data-bound Images
You can add images that are stored in a database to your report. You use the same image control as the one used for static images, but with a set of properties that indicate that the image is stored in a database. To view instructions about working with data-bound images, see How to: Add a Data-Bound Image (Image Wizard).
Change History
Release | History |
---|---|
12 December 2006 |
|
See Also
Concepts
Designing the Report Layout
Working With Fields in a Report Dataset
Understanding Report Layout and Rendering
Designing for Image Output
Managing Resources
Other Resources
Image Wizard Help (Report Designer)