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

Remove Links (or clear diagram)

Thread ID:

Created:

Updated:

Platform:

Replies:

44640 May 30,2006 04:45 PM UTC May 31,2006 10:33 AM UTC WinForms 2
loading
Tags: Diagram
Nick Gardner
Asked On May 30, 2006 04:45 PM UTC

I have a diagram control to which I add rectangle symbols via the InsertNodesCmd. I then link these rectangles using the LinkCmd. I then want to clear the diagram. I can remove the rectangle symbols by using the RemoveNodesCmd. How can I remove the links, or better still is there a quick way to clear a diagram? Thanks in advance, Nick

Administrator [Syncfusion]
Replied On May 31, 2006 07:27 AM UTC

Hi Nick, Thanks for your interest in Syncfusion. If your intention is to remove\delete any particular node please try the following method, // Deletes the selected node(s). this.diagram.Controller.Delete(); Also, if you need to clear the nodes on the Diagram, then you can go with this by using the LayerCollection.RemoveAllMembers() method that removes all the nodes and layers as well. private void button_ClearNodes_Click(object sender, System.EventArgs e) { LayerCollection layers = this.diagram1.Model.Layers as LayerCollection; this.diagram1.Controller.SelectionList.Clear(); // RemoveAllMembers() method clears out every layer in the collection. layers.RemoveAllMembers(); this.diagram1.Controller.UpdateAllViews(); } I hope this information will help you. Please let me know if you need any further assistance. Regards, Praveena.

Nick Gardner
Replied On May 31, 2006 10:33 AM UTC

Super, thanks!

CONFIRMATION

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.

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

;