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

Dynamically choosing TextBlock and Shapes

$
0
0

@abdul.mohamed wrote:

I want to choose TextBlock dynamically based on our nodedataarray.

For example,

diagram.add(
(go.Part, "Vertical", (go.TextBlock, { text: “a Text Block” }), //Textblock 1
(go.TextBlock, { text: "a Text Block", stroke: "red" }), //Textblock 2 (go.TextBlock, { text: “a Text Block”, background: “lightblue” }), //Textblock 3
$(go.TextBlock, { text: “a Text Block”, font: “bold 14pt serif” }) //Textblock 4
));

Now, I want to choose only Textblock 1 for 1st node and Textblock 3 for 5th node. (Dynamically I want to mention which Textblock need to be choosed while defining node in nodearray

Can you help in this?

Posts: 2

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 6969

Trending Articles