We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

how can add a rectangle to diagram

Thread ID:





73522 May 9,2008 04:30 AM UTC May 9,2008 07:32 AM UTC WinForms 1
Tags: Diagram
Asked On May 9, 2008 04:30 AM UTC

I could add diagram programatically in UI.
But how can I add nodes like rectangle/ellipse etc to a diagram?

give me ur valuable suggestions


Administrator [Syncfusion]
Replied On May 9, 2008 07:32 AM UTC

Hi Jiss,

Thank you for using Syncfusion products.

You can use Ellipse and Rectangle classes for creating diagram shapes ellipse and rectangle.

Please use the following code snippet.


// Creating Ellipse
Ellipse ell = new Ellipse(30, 30, 150, 50); this.diagram1.Model.AppendChild(ell);

// Creating Rectangle
Syncfusion.Windows.Forms.Diagram.Rectangle rec = new Syncfusion.Windows.Forms.Diagram.Rectangle(90, 190, 70, 70); this.diagram1.Model.AppendChild(rec);

Sample reference :


Please also refer the shipped sample from the below location on creating shapes.

..\My Documents\Syncfusion\EssentialStudio\\Windows\Diagram.Windows\Samples\2.0\Designing Symbols\SimpleFlow

Please let me know if this helps you.



This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

or the page will be automatically redirected to sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon