-
Notifications
You must be signed in to change notification settings - Fork 204
Images in Reports
Images can be placed anywhere in a report — in the page header as a logo, in the body as a product photo, or as a background. The designer supports three image source types: Embedded, External, and Database.
- Right-click the location on the design surface where the image should appear.
- Choose Insert → Image.
- An Image item is placed on the report. Resize it by dragging the handles.
- In the Properties panel (or right-click → Properties), configure the Source, Value, and Sizing fields.
The image file is encoded into the RDL file itself at design time. The report is fully self-contained — no external files required at runtime.
- Set Source to
Embedded. - Click the
...button next to Value to browse for an image file (PNG, JPG, GIF, BMP). - The image is base64-encoded and stored in the RDL XML.
Best for: company logos, static icons, watermarks. Avoid embedding large photos — they increase RDL file size.
The image is loaded from a file path or URL at render time.
- Set Source to
External. - Set Value to a path or URL expression:
="C:\Reports\Images\logo.png"
="https://example.com/images/logo.png"Or make it dynamic using a parameter:
=Parameters!ImagePath.ValueBest for: images that change without editing the report, shared image libraries, images too large to embed.
External paths must be accessible from the server rendering the report. In Docker or cloud environments use absolute paths or URLs; relative paths resolve against the process working directory.
The image is stored as binary data in a database column and retrieved as part of the dataset.
- Set Source to
Database. - Set Value to the field expression:
=Fields!ProductPhoto.ValueThe field must contain binary image data (VARBINARY / BLOB / BYTEA). Set MIMEType to image/jpeg, image/png, etc. to match the stored format.
Best for: product catalogues, employee directories, any report where the image is data.
If the image is not in a database but in application memory (generated, fetched from object storage, etc.), convert it to a base64 string and pass it as a report parameter. See Pass an Image to a Report for the full pattern.
The Sizing property controls how the image is scaled to fit the item's bounding box:
| Value | Behaviour |
|---|---|
AutoSize |
The item resizes to the image's natural dimensions |
Fit |
Stretches the image to fill the item exactly (may distort) |
FitProportional |
Scales to fit while preserving aspect ratio; may leave gaps |
Clip |
Displays the image at natural size and clips any overflow |
For logos, FitProportional is usually the right choice. For background fills, use Fit.
- Enable the page header band: Report → Page Header.
- Insert an Image item into the header band.
- Set Source to
Embeddedand upload your logo. - Set Sizing to
FitProportional. - Resize the item to the desired logo dimensions (e.g. 2in wide × 0.6in tall).
- Position it using the Left and Top properties in the Properties panel.
Show different images based on data using the full expression builder on the Value field:
' Show a red or green status icon based on a field value
=IIf({Status} = "Active", "active_icon.png", "inactive_icon.png")Combine with Source = External and a shared image directory.
- PNG is preferred for logos and icons (lossless, supports transparency).
- JPG is suitable for photographs.
- Keep embedded images under ~200 KB; larger images are better served as External.
- Set a fixed Width and Height on image items for consistent PDF output;
AutoSizecan shift other items on the page if the image dimensions vary.