Quantcast
Channel: GoJS - Northwoods Software
Viewing all articles
Browse latest Browse all 7069

Binding Panel Type

$
0
0

@Sriram wrote:

Hello,

Is there a way to dynamically get the Panel Type from the node data using a binding?

Instead of hardcoding "Auto" as below :

$(go.Panel,
"Auto"
$(go.Shape, "RoundedRectangle", new go.Binding("fill", "color")),
$(go.TextBlock, { margin: 3 }, new go.Binding("text", "key"))
);

bind as below :

$(go.Panel,
new go.Binding("type", "panelType")
$(go.Shape, "RoundedRectangle", new go.Binding("fill", "color")),
$(go.TextBlock, { margin: 3 }, new go.Binding("text", "key"))
);

Thank you!

Posts: 2

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 7069

Trending Articles