auto set a connector to 2 shapes

May 23, 2011 at 4:41 PM

Hello,

I recently new to your project and i realy like the idea.

I wanted to draw several shapes and connect them with a certain degree of automation.

How can i do the connection? since i already know how to draw the shapes and the connectors, but i cant find the way to connect them.

Thanks in advance.

Hugo Vilaça.

Coordinator
May 23, 2011 at 5:44 PM
Hi Hugo

Im afraid I dont have the time to offer support to every user - but you can look at the examples that come with the code - or place a question on the discussion section of the Codeplex site.

Best wishes
James
<!--

On Monday, 23 May 2011 at 17:41, HugoVilaca wrote:

-->

On Monday, 23 May 2011 at 17:41, HugoVilaca wrote:

From: HugoVilaca

Hello,

I recently new to your project and i realy like the idea.

I wanted to draw several shapes and connect them with a certain degree of automation.

How can i do the connection? since i already know how to draw the shapes and the connectors, but i cant find the way to connect them.

Thanks in advance.

Hugo Vilaça.

Read the full discussion online.

To add a post to this discussion, reply to this email (opendiagram@discussions.codeplex.com)

To start a new discussion for this project, email opendiagram@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com


Developer
Jul 6, 2011 at 9:22 AM

Hi Hugo,

in order to connect shapes with connectors (sic) you have to do the following, for example:

this._circ = new Crainiate.Diagramming.Forms.Diagram ( );

this._circ.Model.Shapes.Add ( "1", _shape1 );
this._circ.Model.Shapes.Add ( "2", _shape2 );

Connector _c = new Connector ( );
_c.Start.Shape = this._circ.Model.Shapes [ "1" ];
_c.End.Shape = this._circ.Model.Shapes [ "2" ];

this._circ.Lines.Add ( _c );

Hope this helps.

Sincerely,

José Rui Abreu Mira