Back to Devexpress

DiagramNodeMappingInfo.ImageUrl Property

aspnet-devexpress-dot-web-dot-aspxdiagram-dot-diagramnodemappinginfo-6086347c.md

latest2.3 KB
Original Source

DiagramNodeMappingInfo.ImageUrl Property

Specifies the name of a data source field that provides the URL of a shape’s image.

Namespace : DevExpress.Web.ASPxDiagram

Assembly : DevExpress.Web.ASPxDiagram.v25.2.dll

NuGet Package : DevExpress.Web

Declaration

csharp
[DefaultValue("")]
public string ImageUrl { get; set; }
vb
<DefaultValue("")>
Public Property ImageUrl As String

Property Value

TypeDefaultDescription
StringString.Empty

The field name.

|

Remarks

This property is in effect for nodes of the “CardWithImageOnLeft”, “CardWithImageOnTop”, or “CardWithImageOnRight” type.

Tip

Use the ImageUrl property to customize the image of a node after it is bound to a data source (in the NodeDataBound event).

aspx
<dx:ASPxDiagram ID="Diagram" runat="server" Width="100%" Height="700px"
    NodeDataSourceID="OrgItemDemoDataSource" EdgeDataSourceID="OrgLinkDemoDataSource">
    <Mappings>
        <Node Key="ID" Text="Text" Type="Type" ImageUrl="Picture" />
        <Edge Key="ID" FromKey="FromID" ToKey="ToID" />
    </Mappings>
</dx:ASPxDiagram>

Run Demo: OrgChart Shapes

See Also

NodeDataBound

Bind Diagram to Data

DiagramNodeMappingInfo Class

DiagramNodeMappingInfo Members

DevExpress.Web.ASPxDiagram Namespace