Skip to content

Latest commit

 

History

History
43 lines (34 loc) · 1.23 KB

change-background-image-through-binding.md

File metadata and controls

43 lines (34 loc) · 1.23 KB
title description type page_title slug position tags ticketid res_type
How to Change a Report's Background Image through Binding
Set the BackgroundImage property through Binding
how-to
Change the Background Image of a Report through Binding
change-background-image-through-binding
1479467
kb

Environment

Product Version 14.1.20.618
Product Progress® Telerik® Reporting

Description

How can I change a report's background image based on a specific value? Can I bind the image to a property?

Solution

To set the background image through a [Binding]({%slug telerikreporting/designing-reports/connecting-to-data/expressions/using-expressions/bindings%}), use the Style.BackgroundImage.ImageData property path. The following steps describe the recommended approach:

  1. Reset the BackgroundImage property and remove any configured images.

  2. Select Bindings in the Properties menu of the report.

  3. Create a new binding with the following parameters:

    • Property path: Style.BackgroundImage.ImageData

    • Expression: =IIf(Condition, imageWhenConditionIsTrue, imageWhenConditionIsFalse)