Attempting to connect a Group with a Shape


Author
Message
Ramesh Ramaraj
Ramesh Ramaraj
Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)
Group: Forum Members
Posts: 2, Visits: 1

In the following example, we are trying to connect the Shape BEGIN with the Group using a connector and it cannot find the PORT for the GROUPS.

And unable to figure out how to draw a border around the Groups.

// create the begin shape

NShape begin = factory.CreateShape((int)FlowChartingShapes.Termination);
begin.Bounds =
new NRectangleF(100, 100, 100, 100);
begin.Text =
"BEGIN";
NDrawingView1.Document.ActiveLayer.AddChild(begin);

// create the step1 shape

NShape step1 = factory.CreateShape((int)FlowChartingShapes.Process);

step1.Bounds = new NRectangleF(100, 400, 100, 100);

step1.Text = "STEP1";

// NDrawingView1.Document.ActiveLayer.AddChild(step1);

 

// create the step2 shape

NShape step2 = factory.CreateShape((int)FlowChartingShapes.Process);

step2.Bounds = new NRectangleF(400, 400, 100, 100);

step2.Text = "STEP2";

//NDrawingView1.Document.ActiveLayer.AddChild(step2);

NGroup group1 = new NGroup();

NDrawingView1.Document.ActiveLayer.AddChild(group1);

group1.Shapes.AddChild(step1);

group1.Shapes.AddChild(step2);

 

NStep3Connector connector = null;

connector = CreateConnector(NDrawingView1.Document, begin, "Center", group1, "Center", ConnectorType.TopToBottom, "") as NStep3Connector;


GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...





Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search