Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by steffen olsen on May 30, 2007 11:16
open dhtmlx forum
Multiple selections and ondragin event & dhtmlXtree

Hi,

I have an question about the onDragIn event and multiple selection. I know you have changed your event system, adding addEvent or attachEvent, but I'm not ready to update the dhtmlXtree sw yet.

Therefor I am wondering if you could help me with the following problem

I am using the onDragIn handler to reject or accept nodes dragged into a tree. My callback function gets the id of the dragged item, however if there is multiple selection enabled, and more than one tree node is dragged into the tree, i only receive an event for the fist node.

Is there any way i can get all the node id in an multiple selection on an onDragIn event

Thanks,


Steffen
Answer posted on May 30, 2007 13:12
but I'm not ready to update the dhtmlXtree sw yet.
While new way for attach event introduced, the previous way is fully workable as well, it just recomended to use new syntax where possible ( we may remove old event system in some future version but it is fully available for now)

and more than one tree node is dragged into the tree, i only receive an event for the fist node
while d-n-d next attribute contains collection of draged items
    tree._dragged
to get their IDs next code can be use
    var ids=[];
    for (var i=0; i<this._dragged.length; i++)
       ids.push(this._dragged[i].id);
Answer posted by Darya (Support) on Dec 01, 2014 13:17

Not much can be said in addition to the reply above, but you also can check calendar picker javascript and c# event calendar and find out what we have probably missed in our explanation.