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.
Unfortunately, activation email could not send to your email. Please try again.

How to detect node lane change

Thread ID:





119668 Jul 20,2015 03:36 PM Jul 21,2015 04:11 AM ASP.NET Web Forms 1
Tags: Diagram
Jim Jacobs
Asked On July 20, 2015 03:36 PM


If I drag a shape from one lane and drop it into another the drop event is fired.
This is good.
How can I quickly determine what lane the node is now placed in?
I could iterate through all lanes in the swimlane and examine each child node to see if it matches the one I just dropped, but that sounds like overkill. 
Is there not a simpler way to get the node's parent lane?

Also, if I nudge the shape using the keyboard arrow keys I can move a node from one lane to another, but since there is no event for this (a feature I am waiting for), I cannot detect a lane change.

Any suggestions on how to determine the node's parent lane in the drop event handler?



Shyam G [Syncfusion]
Replied On July 21, 2015 04:11 AM

Hi Jim

Thanks for using Syncfusion products.

Please note that you can find the parent node using the nodes “parent” property and we suggest you to use drag event to achieve your requirement.  Please refer the code snippet below.

Code snippet:

DiagramContent.OnClientDrag = "drag";

function drag(args) {            

            var diagram = $("#diagram").ejDiagram("instance");

            //args.element has the current node(Ex:rectanglenode)

            var node = args.element;

            if (node && args.elementType === "node") {

                //returns the parent element(lane)

                var parent = diagram.findNode(args.element.parent);


Please let me know if any concerns.

Shyam G


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.

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.