BoundImageDashboardItem.ImageDimension Property

Gets or sets the dimension that provides data for the BoundImageDashboardItem.

Namespace: DevExpress.DashboardCommon

Assembly: DevExpress.Dashboard.v18.2.Core.dll


public Dimension ImageDimension { get; set; }
Public Property ImageDimension As Dimension

Property Value

Type Default Description


A Dimension object that provides data for the BoundImageDashboardItem.


Note that the ImageDimension dimension can provide images in two ways, depending on the data binding mode (BoundImageDashboardItem.DataBindingMode).

  • The ImageDimension provides images as byte arrays.
  • The ImageDimension provides parts of URIs used to locate images. For instance, the URI pattern below specifies the path to the folder containing required images.

    C:\Users\Public\Documents\DevExpress Demos 18.2\Components\Data\ProductDetailsImages{0}.jpg

    Dimension values will be inserted at the position of the {0} placeholder.

To learn more, see Providing Images.


The following example shows how to use a Bound Image dashboard item to display a specified image accessible by a predefined URI.

Imports System.Windows.Forms
Imports DevExpress.DashboardCommon
Imports DevExpress.DataAccess.ConnectionParameters
Imports DevExpress.DataAccess.Sql
Imports DevExpress.XtraEditors

Namespace Dashboard_BoundImage
    Partial Public Class Form1
        Inherits XtraForm

        Public Sub New()
            Dim dashboard As New Dashboard()

            Dim xmlParams As New XmlFileConnectionParameters()
            xmlParams.FileName = "..\..\Data\DashboardProductDetails.xml"

            Dim xmlDataSource As New DashboardSqlDataSource("Data Source 1", xmlParams)
            Dim selectQuery As SelectQuery = SelectQueryFluentBuilder.AddTable("Products").
                SelectColumns("Id", "Name", "Description").Build("Query 1")

            Dim boundImage As New BoundImageDashboardItem()
            boundImage.DataSource = xmlDataSource
            boundImage.DataMember = "Query 1"
            boundImage.DataBindingMode = ImageDataBindingMode.Uri
            boundImage.ImageDimension = New Dimension("Name")
            boundImage.UriPattern = "..\..\ProductDetailsImages\{0}.jpg"
            boundImage.SizeMode = ImageSizeMode.Stretch

            Dim comboBox As New ListBoxDashboardItem()
            comboBox.ShowCaption = False
            comboBox.DataSource = xmlDataSource
            comboBox.DataMember = "Query 1"
            comboBox.FilterDimensions.Add(New Dimension("Name"))
            comboBox.ListBoxType = ListBoxDashboardItemType.Radio
            comboBox.ShowAllValue = False

            dashboard.Items.AddRange(comboBox, boundImage)
            dashboardViewer1.Dashboard = dashboard
        End Sub
    End Class
End Namespace
See Also