Skip to main content

DiagramNode.Style Property

Specifies the node style.

Namespace: DevExpress.Web.ASPxDiagram

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

NuGet Package: DevExpress.Web


public string Style { get; set; }

Property Value

Type Description

A string that specifies the style settings.


The style settings must be specified as inline style declarations in string format.

<dx:ASPxDiagram ID="Diagram" runat="server" Width="100%" Height="700px"
    NodeDataSourceID="OrgItemDemoDataSource" EdgeDataSourceID="OrgLinkDemoDataSource"
        <Node Key="ID" Text="Text" Type="Type" ImageUrl="Picture" />
        <Edge Key="ID" FromKey="FromID" ToKey="ToID" />
protected void Diagram_NodeDataBound(object sender, DevExpress.Web.ASPxDiagram.DiagramNodeEventArgs e)
    if ((DiagramShapeType)e.Node.Type == DiagramShapeType.Ellipse) {
        e.Node.Style = "stroke: red";
        e.Node.TextStyle = "font-weight: bold; text-decoration: underline";

The image below shows the result.

DiagramNode - Styles

See Also